This boilerplate is to be used for new projects at Äventyret within the ambition of WP standardization.
- VVV (varyingvagrantvagrants)
- Node – the version specified in
./nvmrc
, preferably installed with nvm - Yarn
VVV is an open source local development environment focused on WordPress, powered by Vagrant.
- Add site to your config/config.yml
project-name:
hosts:
- project-name.test
- Reprovision with
vagrant reload --provision
From your WordPress themes directory, run:
$ composer create-project roots/sage your-theme-name
Run yarn from the theme directory to install dependencies Update bud.config.js with your local dev URL Compile assets with yarn build
$ cd public_html/web/app/themes/project-name
$ nvm use # Makes sure you use the node version specified in .nvmrc (if you use nvm)
$ yarn && yarn build
Access the website: https://project-name.test
Access WordPress admin: https://project-name.test/wp/wp-admin/
Access files:
$ vagrant ssh
$ cd /srv/www/project-name
Start vm:
$ vagrant up
vvv.test/3306/external/external
Build theme assets with hot reload using Yarn:
$ cd public_html/web/app/themes/project-name
$ nvm use # Makes sure you use the node version specified in .nvmrc (if you use nvm)
$ yarn start