@deloitte-digital-au/babel-preset-app-react
Advanced tools
Changelog
1.1.0
webpack-bundle-analyzer
@babel/preset-env
preset configuration to import polyfills based on usage. Babel will add a specific import for each polyfill into each file if the file uses an API that requires a polyfill in the supported environments.webpack-serve
to v2
(note: the dev
option in webpack-serve has been renamed to devMiddleware
)babel
monorepo to v7.0.0-rc.1
Changelog
0.0.8
Changelog
1.0.0
createConfig
function (see breaking changes below)mini-css-extract-plugin-loader
vs style-loader
) (see breaking changes below)build
watch
vue-loader
to v15
v7.0.0-beta.55
autoprefixer
to v9
1.
Previously we exported a single config object. Now we export { baseConfig, createConfig, mergeConfig }
.
Previously, the base config was extended like this:
const config = require('@deloitte-digital-au/webpack-config');
config.entry = {
main: [
'./src/index.js',
],
};
module.exports = config;
Now, the base config is extended like this:
const { createConfig } = require('@deloitte-digital-au/webpack-config');
module.exports = createConfig({
entry: {
main: [
'./src/index.js',
],
},
});
2.
The module rule matching files with an extension of .js.scss
has been removed. If you would like your CSS to be embedded into a JavaScript file and served with style-loader
, simply import
it into a JavaScript file. If you would like your CSS to be extracted to a CSS file, add it to an entry point or @import
it into another CSS / SCSS file.
Changelog
0.0.6
1.
You will need to make changes to your .babelrc
or babel
property in the package.json file.
If not using React, Change:
presets: ["env"]
for presets: ["@deloitte-digital-au/babel-preset-app"]
Or if using React, change:
presets: ["env", "react"]
for presets: ["@deloitte-digital-au/babel-preset-app-react"]
2.
Install babel 7 cli.
npm install @babel/cli --save-dev
3.
Upgrade to the babel 7 polyfill if you are using a polyfill
npm uninstall babel-polyfill --save-dev
npm install @babel/polyfill --save-dev