vip-dashboard
folder within vip-go-mu-plugins.WordPress plugin that provides a new dashboard for VIP Go clients.
The interface is built with React.js.
Make sure you have Node.js and NPM installed. Here's a handy installer for Windows, Mac, and Linux.
The repository is a sub-module of the mu-plugins directory.
Gulp is required to work on this repository. We use Gulp to compile JSX into valid JavaScript and manage other assets such as CSS and images.
To get setup run the following command in the vip-dashboard
directory:
npm install
Once node has completed the install you should set the URL to your local development site in gulpfile.js
. Line 50:
proxylocation: 'vip.w.dev'
You can then run the default gulp task by running:
gulp
The default task watches for changes to files and re-compiles assets when a change is detected. Your browser window will also automatically be refreshed with each change. We also check for JS errors so keep an eye on your console and fix any reported issues.
Before deploying you may wish to run:
gulp compress
This will generate minified versions of the JavaScript ready for production.
Run
make lint
To test your JavaScript for errors.
├── readme.md
├── gulpfile.js
├── package.json
├── Makefile
├── vip-dashboard.php
├── .travis.yml
├── assets
│ └── css
│ └── img
│ └── js
├── components
│ └── ... react components
Compiled assets, do not edit anything here.
Where each react component lives with the relevent JSX and SCSS files.