Skip to content

Commit

Permalink
Add postcss-inline-svg (#212)
Browse files Browse the repository at this point in the history
Lighter 2.x had `postcss-inline-svg`, but in 3.0 it was missing. It broke DDS.

It provides `svg-load` function that inlines SVG into data-uri.
  • Loading branch information
mlajtos authored Mar 11, 2020
1 parent 7870f5c commit 73e2144
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/react-scripts/config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ module.exports = function(webpackEnv, options = {}) {
},
stage: 3,
}),
require('postcss-inline-svg')(),
// Adds PostCSS Normalize as the reset css with default options,
// so that it honors browserslist config in package.json
// which in turn let's users customize the target behavior as per their needs.
Expand Down
28 changes: 28 additions & 0 deletions packages/react-scripts/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions packages/react-scripts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
"optimize-css-assets-webpack-plugin": "5.0.3",
"pnp-webpack-plugin": "1.6.0",
"postcss-flexbugs-fixes": "4.1.0",
"postcss-inline-svg": "^4.1.0",
"postcss-loader": "3.0.0",
"postcss-normalize": "8.0.1",
"postcss-preset-env": "6.7.0",
Expand Down

0 comments on commit 73e2144

Please sign in to comment.