This is the retain-theme
, a custom WordPress theme built with PHP, JavaScript and SCSS.
Ensure you have the following installed on your system:
- Clone the repository:
git clone <repository-url> cd retain-theme
- Install dependencies
npm install
To build the theme, run:
npm run build
This will:
- Compile SCSS to CSS and output it to inc/css/bundle.css
- Compile the JavaScript files and output them to inc/js/bundle.js
To watch for changes and automatically compile them, run:
npm run watch
This will watch for changes in the SCSS files and compile them to inc/css/bundle.css in real-time.
The theme is structured as follows:
- src/js/: Contains JavaScript source files.
- src/sass/: Contains SCSS source files.
- inc/js/: Compiled JavaScript output.
- inc/css/: Compiled CSS output.
- The Webpack configuration is located in webpack.config.js.