Vue.js / Help

Vue Router and GitHub Pages

Vue Router and GitHub Pages

Vue.js / Help · December 1, 2018 at 2:50pm

Has anyone had any issues using GitHub Pages and Vue Rouer? I'm going to be redoing my personal website with Vue and Vue Router, and I wasn't sure if there were any significant barriers or problems that I might encounter before I get started. Does anyone have experience doing these two things, and could maybe provide their perspective on any issues I might encounter? Thanks!


December 1, 2018 at 2:53pm

Shouldn't have any problems (did you read something that indicated you might?). The one setting you may have to tweak is the "base" URL of your app – https://router.vuejs.org/api/#base. As a total aside, I would recommend hosting your Vue site on Netlify (which is also free + fantastic).

  • reply
  • like

December 1, 2018 at 4:13pm

Thanks for a link to that! I noticed the documentation for that says it uses Vue 2. Is support for Vue 3 projected? Or is it easy for me to use Vue 3 in it?

  • reply
  • like

Shouldn't have any problems (did you read something that indicated you might?). The one setting you may have to tweak is the "base" URL of your app – https://router.vuejs.org/api/#base. As a total aside, I would recommend hosting your Vue site on Netlify (which is also free + fantastic).

My previous website was done with React and React Router, and I had some issues getting them both setup with GitHub Pages. I didn't if I should have expected any similar issues with Vue and Vue Router. Thanks for a link to that, I will check it out!

  • reply
  • like

I'm not sure what breaking changes your refering to that will happen in vue 3. I checked the roadmap and did not see anything of that nature (https://github.com/vuejs/roadmap). Do you mean vue cli 3? Netlify is also a good (maybe better) option and of course the zeit platform.

  • reply
  • like

December 1, 2018 at 11:29pm

I'm not sure what breaking changes your refering to that will happen in vue 3. I checked the roadmap and did not see anything of that nature (https://github.com/vuejs/roadmap). Do you mean vue cli 3? Netlify is also a good (maybe better) option and of course the zeit platform.

Yeah, I meant Vue CLI 3 and I had it mixed up in my head. Sorry for the confusion!

I haven't used Netlify before; does it work easily with custom domains (Google Domains)?

  • reply
  • like

December 3, 2018 at 12:18pm

Yeah, I meant Vue CLI 3 and I had it mixed up in my head. Sorry for the confusion!

I haven't used Netlify before; does it work easily with custom domains (Google Domains)?

I'm using Netlify with a custom domain for a Vue based personal site. No issues at all. I also switched over to Netlify DNS because to make things like HTTPS and CDN configuration easier. I had to configure a redirect so that Vue Router could work in history mode. Their documentation is really good and extensive — shouldn't have any major issues.

like-fill
1
  • reply
  • like