Answer the question
In order to leave comments, you need to log in
How to create a SPA using Node.js and Vue.js?
Hello!
There is a website with a menu on it. The user clicks on a button in the menu (for example, Blog) and without reloading the page receives a list of posts from the database, but the site is normally indexed by SEO.
How to solve this problem using node.js and vue.js?
PS: Please show the code,
Thanks in advance!
Answer the question
In order to leave comments, you need to log in
Read this question.
https://toster.ru/q/441372?e=5485607#answer_item_1...
In a nutshell:
SPA and SEO are generally incompatible, so if you need both, then two jobs are done: one is SPA, the second is SSR.
SSR for Vue .
If you want to use Express for rendering Vue, then try https://github.com/express-vue/express-vue
The rest of the solutions have nothing to do with Express at all. With this bible you can use Vue instead of ejs.
Try looking at https://github.com/chrisvfritz/prerender-spa-plugin and https://www.npmjs.com/package/express-history-api-...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question