Vue JS 2 Tutorial #39 - Setting up Routing

Vue JS 2 Tutorial #39 - Setting up Routing

Net Ninja

7 лет назад

84,710 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Lasitha Dulshan
Lasitha Dulshan - 16.08.2022 19:48

Thank you..!

Ответить
Faysal Ahmed
Faysal Ahmed - 15.08.2022 10:46

Its not working man, showing
Export default (imported as 'VueRouter') was not found in 'vue-router'

Ответить
Amir Hosein Malek Pour
Amir Hosein Malek Pour - 11.08.2022 08:56

hey guys, like me, if you are watching this tutorial around today's date and you want to setup your routing based on this episode, you might confront many errors that can be a real headache. Now FYI, vue-cli has added the option for setting up routing in your view project while you are setting up your whole project, so I suggest that you build a new project using vue-cli but this time use manual selecting feature while setting up your project, there is no need to worry about anything, you do not need to change anything much, just add the routing feature to your project, then run and checkout the routing in your new project. hopefully there won't be anything overwhelming if you have watched episodes about routing and you can understand it all in less then 15 minutes then you can add your previous files to this new project folders and use routing feature while following this awesome tutorial.✌

Ответить
Anil Chudasama
Anil Chudasama - 01.05.2021 17:34

thanks buddy

Ответить
Lobsang Gyatso
Lobsang Gyatso - 23.11.2020 13:04

how to avoid page refresh after navigation??? plz

Ответить
Milad Bannourah
Milad Bannourah - 10.10.2020 17:09

unfortunately things are kinda different in 2020 its making this tutorial almost useless

Ответить
Jordy Tshibangu
Jordy Tshibangu - 09.09.2020 08:33

Can I also use vue ui to import and add vue-router ?
Is it the best options ?
why ?

Ответить
Bagas Immanuel
Bagas Immanuel - 26.08.2020 16:08

Thank you for the amazing content :)

Ответить
Filip Fedorišin
Filip Fedorišin - 11.04.2020 14:26

Does not work anymore

Ответить
Han Donghee
Han Donghee - 27.12.2019 06:45

I'm studying vue js in Korea. Thank you for a good lecture.

Ответить
אדם פרי
אדם פרי - 24.03.2019 11:23

The BEST as always!

Ответить
alexchiu
alexchiu - 04.12.2018 22:17

hmm my /add route is not working... just defaults back to showBlogs components..any ideas why anyone?

Ответить
Alok Mani
Alok Mani - 03.10.2018 10:54

Umm, but how to add multiple components in a route?

Ответить
Pradeep kumar V
Pradeep kumar V - 20.09.2018 20:20

Hi
I have a Question.

How do I make the component reload when my router needs to navigate to same route path
(Lets says user has navigated to About Page from Home Page ,and when he clicks About Page again ,then the About Page component has to be fully reloaded irrespective of the state)

Ответить
vigilantezack
vigilantezack - 15.08.2018 00:18

This routing feels weird. I mean, you will eventually route to every page/component in the site, so that means eventually you are importing every single component at the top of the file!
Just feels inefficient somehow.

Hopefully Vue or JS can someday do something like PHP autoloading so that it can automatically find and load the files without explicitly importing them everywhere.

Ответить
daniel gabe
daniel gabe - 05.08.2018 19:47

Thankyou very much

Ответить
continental_drift
continental_drift - 25.04.2018 16:01

I tested my code before proceeding so I know it works before adding and removing parts. When I remove "<show-Blogs> and <list-Blogs>" and replace them with <router-view> nothing displays, I don't get any errors.
Where does "<router-view>" come from ? I haven't seen it defined anywhere.

Ответить
Дмитрий Шаповалов
Дмитрий Шаповалов - 03.04.2018 01:46

Dont work routing.
'Failed to compile - can't resolve: "vue.resource"'

Ответить
Cyril M
Cyril M - 23.03.2018 00:38

Thanks for this amazing tutorial ! Each of your tutorial deserves a comment :)

Ответить
Nelly P
Nelly P - 27.02.2018 01:25

Now, as a Brit.....is it 'Routing' or 'Rooting'???

Ответить
Clive Sargeant
Clive Sargeant - 01.01.2018 18:01

Nice tutorial. Excellent video and audio quality and well explained! thanks.

Ответить
Павел Ефименко
Павел Ефименко - 26.11.2017 21:56

just perfect

Ответить
Jens Törnell
Jens Törnell - 01.11.2017 12:23

Why not use var instead of const? var is a bit shorter.

Ответить
realTalents
realTalents - 11.09.2017 13:40

My addblog component isn't rendering -- only the showblogs renders when I navigate to '/' and '/add' I'm stuck right now. Please helpOne more thing, isn't is possible to connect to mysql database in VueCli environment?Thanks man...

Ответить