Skip to content

Commit

Permalink
update version number and compile js assets
Browse files Browse the repository at this point in the history
  • Loading branch information
bacoords committed Jun 17, 2021
1 parent ea868b7 commit 1d21a86
Show file tree
Hide file tree
Showing 6 changed files with 1,547 additions and 1,519 deletions.
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Understrap Child Theme shares with the parent theme all PHP files and adds its o
Understrap Child Theme uses the Enqueue method to load and sort the CSS file the right way instead of the old @import method.

## Installation
1. Install the parent theme UnderStrap first: `https://github.com/understrap/understrap`
1. Install the parent theme UnderStrap first: `https://github.com/understrap/understrap` or `https://wordpress.org/themes/understrap/`
- IMPORTANT: If you download UnderStrap from GitHub make sure you rename the "understrap-master.zip" file to "understrap.zip" or you might have problems using this child theme!
1. Upload the understrap-child folder to your wp-content/themes directory
1. Go into your WP admin backend
Expand All @@ -32,6 +32,8 @@ It will be outputted into:

So you have one clean CSS file at the end and just one request.

Add your own JS files to `src/js/` to have them bundled into child-theme.js.

## Developing With NPM, Gulp, SASS and Browser Sync

### Installing Dependencies
Expand All @@ -49,8 +51,9 @@ Or, to run with Browser-Sync:
- First change the browser-sync options to reflect your environment in the file `/gulpconfig.json` in the beginning of the file:
```javascript
"browserSyncOptions" : {
"proxy": "localhost/wordpress/",
"notify": false
"proxy": "localhost/",
"notify": false,
"files": ["./css/*.min.css", "./js/*.min.js", "./**/*.php"]
}
};
```
Expand Down
4 changes: 2 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -196,14 +196,14 @@ gulp.task( 'scripts', function() {
gulp
.src( scripts, { allowEmpty: true } )
.pipe( babel( { presets: ['@babel/preset-env'] } ) )
.pipe( concat( 'theme.min.js' ) )
.pipe( concat( 'child-theme.min.js' ) )
.pipe( uglify() )
.pipe( gulp.dest( paths.js ) );

return gulp
.src( scripts, { allowEmpty: true } )
.pipe( babel() )
.pipe( concat( 'theme.js' ) )
.pipe( concat( 'child-theme.js' ) )
.pipe( gulp.dest( paths.js ) );
} );

Expand Down
Loading

0 comments on commit 1d21a86

Please sign in to comment.