WP Vue is a Vue blog template
WP Vue
This blog can handle a WordPress REST endpoint and display its contents. The blog in its core has Vue components but it can be modified to suit your own needs.
It was inspired by Dave Rupert and Chris Coyier's Shop Talk Show podcast, when they were discussing how a blog built with a JavaScript framework and powered by the WordPress REST API might look like. It's intended to be ripped apart by developers and made to suit their needs, and everyone's encouraged to contribute if they have ideas that might improve the template and benefit others.
Make it yours
- Make sure you have
yarn
installed on your machine, and runyarn install
.
Set Your Constants
Set your specific constants in the config.js
file.
REST_ENDPOINT
- The WordPress REST API endpoint from which data will be pulled. Leave off the trailing slash. Example:https://blah-blah-blah.com/wp-json/wp/v2
POSTS_PER_PAGE
- The default number of posts per page that will be displayed.GA_TRACKING_ID
- A Google Analytics tracking ID.
Run yarn run dev
to spin up a running version from localhost.
Deploy to Netlify
The app is deployed to Netlify, so it is a great place to host your own version of this project. The running app gives the user the option to change to another REST API endpoint.
This is an open source project, licensed under MIT. By Alex MacArthur