chasegiunta / craft-vue

All the power of Vue CLI's scaffolding, dev tools, and single file components tailored for a Craft CMS project.
The Unlicense
97 stars 24 forks source link

Handling Prerendering #17

Closed Michael-Reich closed 5 years ago

Michael-Reich commented 5 years ago

We currently consider this approach for one of our projects. So one question I have is how I could fix the prerendering problem.

Currently the routes are managed by craft. I tried to use Vue Prerender as a framework to prerender vue components, but the problem is, that there is no vue router right?

Would be great to hear youre opinion on this.

chasegiunta commented 5 years ago

@Michael-Reich I haven't dealt with pre-rendering with this yet. Typically anything vital that I want to be dynamic & crawlable I put into slots - but you shouldn't feel the need to place all your content within components.

chasegiunta commented 5 years ago

Closing for now. Feel free to follow up if you did any more digging

Michael-Reich commented 4 years ago

GoodWork Page is built with this setup right? Because if I view Source code there is the whole HTML structure, so SEO is perfectly working right? How did you achieve this, by using vue and craft?

TY!

chasegiunta commented 4 years ago

@Michael-Reich Yes, the Good Work site is built using this same setup, but it's not an SPA. This setup is essentially mounting the entire body on every page load, and giving you globally registered components out of the box. Routing is being done through Craft.