A starter template for WordPress websites featuring Docker, Gulp and Webpack
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app
gulp
js
sass
.babelrc
.gitignore
Dockerfile
Makefile
README.md
docker-compose.yml
dwp
gulpfile.js
package.json
yarn.lock

README.md

WordPress starter

A starter template for WordPress websites featuring Docker, Gulp and Webpack.

Getting started

Prerequisites

  • Node.js -> 8.0.0
  • Yarn -> 1.0.0
  • Composer -> 1.5.1
  • Docker -> 17.12
    • docker-compose -> 1.16.1

Setup

Step 1: First rename the md-starter-theme folder using your theme-name.

Step 2: Then rename every occurrence of md-starter-theme in the parent folder (except in ./README.md) using your theme-name.

Step 3: You can now edit all informations related to your theme in style.css:

/**
 * Theme Name: MD starter theme
 * Author: MD
 * Author URI: https://wearemd.com
 * Version: 1.0.0
 * Text Domain: md-starter-theme
 */

Step 4 (optional): WordPress will be downloaded in french by default. If you want your website to be in another language, set --locale in Makefile. See the Complete List of WordPress Locale Codes.

Step 5: Finally run make setup to get everything ready:

  • Docker containers
  • WordPress download
  • WordPress configuration
  • Etc.

Your WordPress is ready to be themed, well done fella 👊

Serve

make

Build

make build_assets: Compile theme assets for production

Versioning

When you update the WordPress theme, don’t forget to change the theme version number in style.css before deploying. This version number will append to CSS/JS files to bust browser cache on those assets.

Folders

  • app/wp-content/themes/md-starter-theme: WordPress theme
  • gulp: Gulp tasks and configuration
  • sass: Theme Sass files (edit those files to update your theme CSS)