Hi. I'm a starter theme called wp_default_starter. I exist to provide a serious boost to Phase 3 WordPress Theme Development. This theme was created under a few assumptions:
- You are using WordPress with Gutenberg & the Genesis Framework.
- You are using the Genesis Custom Block Builder provided by Genesis Pro.
The build process of this starter theme is set up for this process. The theme can be modified by removing or commenting out the following:
- Comment out the
blockStyles&blockStylesRTLtask. - Remove the
blockStylestask from the gulp default task. - Remove the
blockStylestask from the gulp production task.
- Remove the
blocksdirectory - Remove the
src/scss/blocksdirectory
This should resolve any potential compilation errors since you will not utilize these files or functions. Everything else should compile as expected.
This starter theme should be installed in the themes directory of your WordPress installation.
Incidentally, you'll also require a local WordPress installation. Local, a product from Flywheel & WP Engine, is the quickest and easiest way to set up a local WordPress environment.
This project will require the following dependencies:
Clone or download this repository, change its name to something else (like, say, megatherium-is-awesome), and then you'll need to do a six-step find and replace on the name in all the templates.
- Search for
'wp_starter_theme'(inside single quotations) to capture the text domain and replace with:'megatherium-is-awesome'. - Search for
wp_starter_theme_to capture all the functions names and replace with:megatherium_is_awesome_. - Search for
Text Domain: wp_starter_themeinstyle.cssand replace with:Text Domain: megatherium-is-awesome. - Search for
wp_starter_theme(with a space before it) to capture DocBlocks and replace with:Megatherium_is_Awesome. - Search for
wp_starter_theme-to capture prefixed handles and replace with:megatherium-is-awesome-. - Search for
WP_STARTER_THEME(in uppercase) to capture constants and replace with:MEGATHERIUM_IS_AWESOME_.
Then, update the stylesheet header in style.css, the links in footer.php with your own information and rename _wp_default_starter.pot from languages folder to use the theme's slug. Next, update or delete this readme.
$ yarn install
$ composer installwp_default_starter comes packed with CLI commands tailored for WordPress theme development :
yarn start: starts the development BrowserSync serveryarn build: compiles the theme into a production ready buildyarn styles: compiles only the stylesyarn blockStyles: compiles only the Block Stylesyarn stylesRTL: compiles only the RTL stylesyarn blockStylesRTL: compiles only the RTL block stylesyarn vendorsJS: compiles the vendor javascriptyarn customJS: compiles the custom JS filesyarn images: optimizes the imagesyarn clearCache: clears the cacheyarn translate: runs translationscomposer lint:wpcs: checks all PHP files against PHP Coding Standards.composer lint:php: checks all PHP files for syntax errors.composer make-pot: generates a .pot file in thelanguages/directory.run compile:css: compiles SASS files to css.npm run compile:rtl: generates an RTL stylesheet.npm run watch: watches all SASS files and recompiles them to css when they change.
Now you're ready to go! The next step is easy to say, but harder to do: make an awesome WordPress theme. :)
Good luck!