Skip to content
This repository has been archived by the owner on Jun 17, 2021. It is now read-only.

Commit

Permalink
🔧 stop renaming keyframes, counter and gridTemplate
Browse files Browse the repository at this point in the history
  • Loading branch information
knuch committed May 1, 2019
1 parent f0e6ee7 commit 23dfe4c
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 16 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@
"gulp-cheerio": "^0.6.3",
"gulp-concat": "^2.6.1",
"gulp-consolidate": "^0.2.0",
"gulp-cssnano": "^2.1.3",
"gulp-eslint": "^4.0.2",
"gulp-gh-pages": "^0.5.4",
"gulp-load-plugins": "^1.5.0",
Expand Down
8 changes: 5 additions & 3 deletions tasks/styles.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,11 @@ const stylesBuild = () => {
.pipe($.postcss([
autoprefixer({ grid: true }),
require('cssnano')({
preset: ['default', {
reduceIdents: false,
}],
reduceIdents: {
keyframes: false,
gridTemplate: false,
counter: false,
},
}),
]))
.pipe($.rename((path) => {
Expand Down
10 changes: 9 additions & 1 deletion tasks/vendors.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,15 @@ const cssVendors = (done) => {
if (config.vendors.css.length > 0) {
return gulp.src(config.vendors.css, {cwd: config.project})
.pipe($.concat('vendors.min.css'))
.pipe($.cssnano())
.pipe($.postcss([
require('cssnano')({
reduceIdents: {
keyframes: false,
gridTemplate: false,
counter: false,
},
}),
]))
.pipe($.size({title: 'CSS VENDORS', showFiles: true}))
.pipe(gulp.dest(`${config.dest}css`, {cwd: config.project}));
}
Expand Down
12 changes: 1 addition & 11 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2221,7 +2221,7 @@ [email protected], css@^2.2.1:
source-map-resolve "^0.5.1"
urix "^0.1.0"

cssnano@^3.0.0, cssnano@^3.10.0:
cssnano@^3.10.0:
version "3.10.0"
resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-3.10.0.tgz#4f38f6cea2b9b17fa01490f23f1dc68ea65c1c38"
dependencies:
Expand Down Expand Up @@ -3783,16 +3783,6 @@ gulp-consolidate@^0.2.0:
consolidate "~0.14.0"
map-stream "0.0.4"

gulp-cssnano@^2.1.3:
version "2.1.3"
resolved "https://registry.yarnpkg.com/gulp-cssnano/-/gulp-cssnano-2.1.3.tgz#02007e2817af09b3688482b430ad7db807aebf72"
dependencies:
buffer-from "^1.0.0"
cssnano "^3.0.0"
object-assign "^4.0.1"
plugin-error "^1.0.1"
vinyl-sourcemaps-apply "^0.2.1"

gulp-eslint@^4.0.2:
version "4.0.2"
resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-4.0.2.tgz#18a2a6768e4404cbf3e203239cb57474168fa606"
Expand Down

0 comments on commit 23dfe4c

Please sign in to comment.