Ad

VUEJS SSR, How To?

- 1 answer

I made a VueJS 3 app (WebPack 3.12.0), with prerendering (not serverside), and the content of some page are loaded via ajax request, so google bots can't see the text (this is the problem here).

I read that I need to use SSR to do this. So I tried a couple of tutorials but no one seem to works (some do nothing, others crashes my app). I don't really know which one is the best and they are all using differents solutions.

First of all, do I need to use SSR to achieve what I want ? And if yes, anyone have a good tutorial (and a working one) ?

Thanks guys !

Ad

Answer

The best solution for SSR with Vue is to use Nuxt.js: https://nuxtjs.org/

It's not that complex, working really great !
It will probably be migrated to Vue3 really soon (Nuxt 2.15.2 is using Vue2 still), maybe even today during the JS World Conference.

Also, you can check those videos of Debbie who does a nice job of explaining things in a clear and simple way: https://www.youtube.com/c/DebbieOBrien/videos

Ad
source: stackoverflow.com
Ad