File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -31,6 +31,13 @@ function css() {
3131 // if NODE_ENV === production, no sourcemaps and minify the css
3232 const path = `${ sourcePath } /stylesheets/_main.css` ;
3333
34+ // autoprefix more browsers for demo page
35+ var browsers = [ "safari 13" ] ;
36+ if ( process . env . NODE_ENV === "demo" ) {
37+ console . log ( "its a demo" ) ;
38+ browsers = [ "last 4 version" ] ;
39+ }
40+
3441 if (
3542 process . env . NODE_ENV != "production"
3643 || process . env . NODE_ENV != "demo"
@@ -39,15 +46,15 @@ function css() {
3946 . pipe ( sourcemaps . init ( ) )
4047 . pipe ( postcss ( [
4148 atImport ( ) ,
42- autoprefixer ( { overrideBrowserslist : [ "safari 13" ] } )
49+ autoprefixer ( { overrideBrowserslist : browsers } )
4350 ] ) )
4451 . pipe ( sourcemaps . write ( ) )
4552 . pipe ( dest ( outputPath ) ) ;
4653 } else {
4754 return src ( path )
4855 . pipe ( postcss ( [
4956 atImport ( ) ,
50- autoprefixer ( { overrideBrowserslist : [ "defaults" ] } )
57+ autoprefixer ( { overrideBrowserslist : browsers } )
5158 ] ) )
5259 . pipe ( dest ( outputPath ) ) ;
5360 }
You can’t perform that action at this time.
0 commit comments