Rescript PostCSS is a Rescripts configuration that lets you use your own PostCSS configuration in Create React App without ejecting.
Add Rescript PostCSS to your project:
npm install rescript-use-postcss-config --save-dev
Next, add Rescript PostCSS to your Rescript configuration:
// .rescriptsrc.js
module.exports = [
['use-postcss-config']
]
Use your own PostCSS configuration:
// .postcssrc.js
module.exports = {
map: true,
plugins: {
'postcss-preset-env': { stage: 0 }
}
}