Skip to content

Latest commit

 

History

History
28 lines (18 loc) · 1.14 KB

README.md

File metadata and controls

28 lines (18 loc) · 1.14 KB

Wordpress-dev-env

When I was developing a wordpress theme using _s (Underscore), I need:

  1. auto compiling .scss to .css on save,
  2. auto refreshing browser. Here stores some key files.

The files mainly come from a course on Lynda.com (the course is deprecated. I searched it out on google) which is about _s.

WordPress: Building Themes from Scratch Using Underscores by Morten Rand-Hendriksen @mor10

But the packages are quite old. While running in Sep, 2020, meets so many inconsistancy and vulnerabilities.

I don't know where to find new ways to meet my needs, so I tried to repair it.

It works just fine.

Usage

Make sure you have installed Node.js.

  1. Under 'themes' folder of Wordpress site, create a new folder, name it what ever you want, by convention, I name it 'gulp-dev'.
  2. Put Gulpfile.js and package.json into the folder.
  3. Change placeholders near line 1 and line 68 of Gulpfile.js
  4. Go to the folder in terminal.
  5. npm install
  6. gulp