gridsome-starter-wordpress icon indicating copy to clipboard operation
gridsome-starter-wordpress copied to clipboard

Updating for v0.7, Routes/Templates

Open petethompson opened this issue 5 years ago • 3 comments

@hjvedvik - I'm updating the wordpress starter to be compatible with gridsome 0.7, at least on my fork, for a future PR. The only deprecation notices I'm still getting are regarding using templates for routes in addCollection().

Since there's no gridsome.config.js in the starter, I'm not sure how or where to add the Templates configuration in this context. Can you point me in the right direction?

petethompson avatar Sep 18 '19 16:09 petethompson

The current master branch should be compatible with 0.7 already. Here is the gridsome.config.js file with the templates config. And here is the starter running v0.7.3 on Netlify :)

hjvedvik avatar Sep 18 '19 16:09 hjvedvik

Ah, I see. Thanks! How should I update source-wordpress, within my existing projects?

I ran npm install @gridsome/source-wordpress latest on my project and it's still using addContentType() with routes defined.

petethompson avatar Sep 18 '19 16:09 petethompson

By the way, I was originally mistakenly referring to the routes in the @gridsome/source-wordpress package, assuming that was part of the wordpress starter. My bad!

petethompson avatar Sep 18 '19 18:09 petethompson