Changed:
- Explicitly call
process.exit(0)from thenwbcommand when there are no errors running a command [#262]
Fixed:
- Fixed blank version being set for the React
peerDependencyin newreact-componentprojects. - Use the transpiled ES5 version of
preact-compatfor compatibility builds usingreact buildwith the--preactflag, to prevent UglifyJS errors [#244]
Changed:
- Support the Array version of deprecated
webpack.postcssconfig. - Tell the user they're including redundant config if they've manually configured inferno-compat or preact-compat aliases for React modules [#247]
Fixed:
-
Added a missing
.defaultto the Preact project skeleton where CommonJSrequire()was being used to import an ES module [#245].defaultmust now be used to access the default export from an ES module when importing with CommonJSrequire()as Webpack 2 prevents module format mixing, which was previously used to provide CommonJS interop.
Fixed:
- Use the transpiled ES5 version of
preact-compat, as UglifyJS can't handle the ESmodulebuild [#244]
Removed:
- Remove hints about possibly not needing
babel.cherryPickdue to Webpack 2 tree shaking, as this doesn't currently appear to be true.
Breaking Changes:
-
Upgraded from Webpack 1 to Webpack 2 [#110]
Minimum Node.js version increased from 4.2 to 4.3 - this is Webpack 2's minimum supported Node.js version.
Strict Webpack configuration - Webpack 2 is strict about what appears in its configuration object. If you're using
webpack.extraconfig, it must conform to Webpack 2's configuration format or your build will fail with a validation error.Dropped CommonJS compatibility when importing ES modules - Webpack 2 no longer allows you to mix CommonJS modules with ECMAScript modules - if a module uses
importorexportsyntax,exportswill beundefinedandmodule.exportswill be read-only andundefined.As a result, we can no longer provide CommonJS interop by default for ES Modules - you will need to check your code for usage of CommonJS
require()to import ES modules and tack a.defaulton the end if you need to use the module'sexport default.If you used nwb's Preact project skeleton, the
init()function inindex.jsneeds to have a.defaulttacked on when theAppcomponent is being imported.Custom top-level properties no longer allowed in Webpack configuration - Webpack 2 no longer allows custom top-level properties in its configuration. Loader configuration which can't be serialised, such as plugin objects, can now be provided directly as loader options instead using
webpack.rulesconfig instead.This includes
postcss-loader, which is now configured viawebpack.rulesinstead of having its own specialwebpack.postcssconfig.
nwb.config.js Config Format Changes:
For deprecations, nwb will continue to support the old format for the next couple of releases, displaying warning messages about the changes required and adapting deprecated config for use in the current version where possible.
If you have an
nwb.config.jsfile, runnwb check-configafter updating nwb to find out if there's anything you need to change.
-
Deprecated
karma.testDirs, renaming this config tokarma.excludeFromCoverage, as it can be configured to exclude any paths from code coverage, not just directories [#236]// < v0.15 // v0.15 module.exports = { module.exports = { karma: { karma: { testDirs: [ => excludeFromCoverage: [ 'test/', 'test/', 'path/to/ignorethis.js' 'path/to/ignorethis.js' ] ] } } } }
-
Deprecated
webpack.loaders, renaming this config towebpack.rulesto match Webpack 2's new config format:// < v0.15 // v0.15 module.exports = { module.exports = { webpack: { webpack: { loaders: { => rules: { /* ... */ /* ... */ } } } } } }
-
Deprecated use of a
queryproperty to configure Webpack rule options as a separate object - anoptionsproperty should now be used as per Webpack 2's new config format:// < v0.15 // v0.15 module.exports = { module.exports = { webpack: { webpack: { loaders: { rules: { css: { css: { query: { => options: { modules: /* ... */ modules: /* ... */ } } } } } } } } } }
You can also still configure loader options as a flat object to make this particular change irrelevant:
module.exports = { webpack: { rules: { css: { modules: /* ... */ } } } }
-
Deprecated configuring PostCSS plugins with special
webpack.postcssconfig - postcss-loader can now be configured like any other loader usingwebpack.rulesconfig:// < v0.15 // v0.15 module.exports = { module.exports = { webpack: { webpack: { postcss: [ => rules: { require('precss')(), postcss: { require('autoprefixer')() plugins: [ ] require('precss')(), } require('autoprefixer')() } ] } } } }
Removed:
- Removed support for configuration which was deprecated in nwb v0.12.
- Removed support for
json-schemainwebpack.compatconfig, as this library has now been fixed [#227]
Dependencies:
- autoprefixer: v6.6.1 → v6.7.0
- babel-cli: v6.18.0 → v6.22.2
- babel-core: v6.21.0 → v6.22.1
- babel-plugin-inferno: v1.5.0 → v1.7.0 - make plugin ES5-environment compatible; add option to import
createVNode - babel-plugin-transform-react-jsx: v6.8.0 → v6.22.0
- babel-plugin-transform-react-jsx-self: v6.11.0 → v6.22.0
- babel-plugin-transform-react-jsx-source: v6.9.0 → v6.22.0
- babel-plugin-transform-runtime: v6.15.0 → v6.22.0
- babel-polyfill: v6.20.0 → v6.22.0
- babel-preset-es2015: v6.18.0 → v6.22.0
- babel-preset-es2016: v6.16.0 → v6.22.0
- babel-preset-react : v6.16.0 → v6.22.0
- babel-preset-stage-0: v6.16.0 → v6.22.0
- babel-preset-stage-1: v6.16.0 → v6.22.0
- babel-preset-stage-2: v6.18.0 → v6.22.0
- babel-preset-stage-3: v6.17.0 → v6.22.0
- babel-runtime: v6.20.0 → v6.22.0
- detect-port: v1.0.7 → v1.1.0
- filesize: v3.3.0 → v3.4.3
- html-webpack-plugin: v2.24.1 → v2.26.0 - Webpack 2 RC support
- inquirer: v2.0.0 → v3.0.1 - drop Node.js v0.12 support
- karma: v1.3.0 → v1.4.0
- karma-mocha-reporter: v2.2.1 → v2.2.2
- karma-webpack: v1.8.0 → v2.0.1 - Webpack 2 RC support
- object-assign: v4.1.0 → v4.1.1
- ora: v0.4.1 → v1.1.0 - text can now be changed while stopping and persisting
- postcss-loader: v1.2.1 → v1.2.2
- webpack: v1.14.0 → v2.2.0 - \o/
- webpack-merge: v2.3.1 → v2.4.0
- whatwg-fetch: v2.0.1 → v2.0.2
Temporarily Scoped Dependencies:
These are being scoped to both make use of unreleased features and to test them out:
- @insin/extract-text-webpack-plugin - scoped until this PR is merged and released
- @insin/npm-install-webpack-plugin - scoped until new features are merged and released
Internal:
- Dropped unused
fs-extradependency. - Use
babel-preset-envwhen transpiling tolib/, targeting Node.js v4 [#233] - Use ES2015
Stringmethods available in Node.js v4 instead ofString.prototype.indexOfcomparisons [#222]
Fixed:
Fixed:
- Fix using Express middleware with a config file which exports a function [#238]
Fixed:
- Fix running tests with base config only (
web-appandweb-moduleprojects).
Dependencies:
- Downgrade
html-webpack-pluginto v2.24.1 while issues later versions cause withnpm-install-webpack-pluginare unresolved.
Fixed:
- To prevent version compatibility issues using project commands from a globally-installed
nwb, it will now exit with a warning if the project specifies a different version of nwb inpackage.json[#167]- The ability to run project commands like
build,serveetc. from a globalnwbinstall is provided so you don't have to reinstall the entirety of nwb when creating new projects, but it's recommended that you switch to a locally-installed version later, as relying on globally-installed tool versions is brittle.
- The ability to run project commands like
- Fix
cleancommands in paths with spaces [#181]
Added:
- Added an
infernocommand for quick Inferno prototyping and building. Useinferno run <entry.js>to serve a module andinferno build <entry.js> [dist/]to build it. - Added a
preactcommand for quick Preact prototyping and building. Usepreact run <entry.js>to serve a module andpreact build <entry.js> [dist/]to build it. - The
infernoandpreactcommands use a render shim module by default which hooks intoInferno.render()andPreact.render()to intercept the incoming VNode and re-render it from the top when accepting Hot Module Replacement, so if you're callingrender()yourself you don't have to specify a DOM node, or arootwhen re-rendering in Preact.- If you want to take full control of rendering, use the
--forceflag and nwb will skip the render shim and use your entry module directly. - The
reactcommand's render shim doesn't hook intoReactDOM.render()and only handles rendering exported components or elements for convenient prototyping, as react-transform-hmr handles the details of accepting Hot Module Replacement and patching/re-rendering at the component/module level.
- If you want to take full control of rendering, use the
- Added new features which are available in the
infernoandpreactcommands to the existingreactcommand:- Added a
--pluginsoption to specify nwb plugins which should be installed and used without having to set up apackage.json. - Added a
--forceoption to force use of the provided entry module directly instead of the render shim module which is used by default to support quick prototyping. - Added a
--no-polyfilloption to disable inclusion of nwb's default polyfills forPromise,fetch()andObject.assign()if you're not using them or don't need them polyfilled. - Inferno compat and Preact compat dependencies are now automatically installed if missing.
react buildcan now build a module which exports a React component or element, for quick sharing of prototypes.
- Added a
- Inferno and Preact apps are now configured to use their respective React compatibility modules by default if
reactorreact-domare imported, allowing use of existing React code out of the box.
Changed:
- The Webpack manifest module is now generated when building an app (as well as being inlined into the generated
index.html) - you will need to include this first if manually handling HTML generation after building. - Express middleware now supports Inferno, Preact and plain JavaScript apps, not just React.
- When building a React app using the
--infernoor--preactflags, the required compatibility dependencies are now installed automatically if they can't be resolved from your project directory. - When creating new projects, the latest version of dependencies will be installed, rather than using a a version range hardcoded in nwb.
- Skip initialising a Git repo if a
.git/directory already exists, e.g. you may want to usenwb initin an existing repo. - The default build for a React component demo app now supports use of a
demo/public/directory for static content. - An
argsproperty is now included in the object passed to user configs which export a function - this contains parsed arguments, e.g.args.preactwill betrueif you passed--preactwhen callingnwb.
Removed:
- Removed support for using
--set-env-VAR_NAMEarguments to set environment variables. jsnext:mainis no longer includedpackage.jsonfor newreact-componentandweb-moduleprojects - only the "more standard"moduleproperty is used to point to an ES2015 modules build [#215]
Dependencies:
- autoprefixer: v6.5.3 → v6.6.1
- babel-core: v6.20.1 → v6.21.0
- babel-loader: v6.2.9 → v6.2.10 - Webpack 2 RC support
- babel-plugin-inferno: v1.4.0 → v1.5.0 - use import instead of global Inferno reference
- babel-plugin-istanbul: v3.0.0 → v3.1.2
- babel-plugin-lodash: v3.2.10 → v3.2.11
- detect-port: v1.0.6 → v1.0.7
- diff: v3.1.0 → v3.2.0
- html-webpack-plugin: v2.24.1 → v2.26.0 - Webpack 2 RC support
- karma-webpack: v1.8.0 → v1.8.1 - Webpack 2 RC support
- ora: v0.3.0 → v0.4.1
- phantomjs-prebuilt: v2.1.13 → v2.1.14
- postcss-loader: v1.2.0 → v1.2.1
- resolve: v1.1.7 → v1.2.0
- webpack-dev-middleware: v1.8.4 → v1.9.0 - Webpack 2 RC support
- webpack-hot-middleware: v2.13.2 → v2.15.0 - add cache for warnings
- webpack-merge: v1.0.2 → v2.3.1 - providing an empty array/object no longer overrides when merging
Changed:
- Inferno apps now use Inferno 1.x by default.
Dependencies:
- babel-plugin-inferno: v1.3.0-beta17 → v1.4.0
Fixed:
- Updated Inferno Babel plugin to fix whitespace trimming issue.
Changed:
- Updated default Inferno version for new apps to 1.0.0-beta42.
Dependencies:
- babel-plugin-inferno: v1.2.0-beta13 → v1.3.0-beta17 - fixes whitespace trimming around newlines
Fixed:
-
Don't configure the babel runtime transform's
moduleNamepath when transpiling code for npm [#205]If you depend on
babel-runtimein a React component or Web module (by usingasync/awaitor enabling any of the runtime transform's other features) it needs to be resolvable from the end-user's dependencies, so should be added to your project'speerDependencies.
Fixed:
Fixed:
Fixed:
- Fix npm scripts in the
inferno-appskeleton.
Fixed:
- Initialise a Git repo for a new project after installing dependencies, so package.json includes dependencies saved by npm in the initial commit.
Added:
- Added a
--copy-filesflag for React component builds to copy files which will not be transpiled over to the build directories [#58]
Added:
- Added new project types:
inferno-appandpreact-app- use these withnwb newornwb initto develop Inferno and Preact apps [#194] - Added an
--infernoflag to React app builds to create an inferno-compat build [#194] react-jsx-sourceandreact-jsx-selfBabel transforms are now enabled for React apps in development mode for improved debugging.- A Git repo with an initial commit is now created by default when creating a new project. Pass a
--no-gitflag to disable this. - Added project-specific variants of
nwb test:nwb test-react,nwb-test-infernoandnwb-test-preact. - Added an
audioloader and ansvgloader.
Removed:
- Removed hardcoded React preset from default Babel config when running tests - instead,
nwb testwill run the newnwb test-reactcommand if you have areact-apporreact-componentproject type innwb.config.js. - Dependencies are no longer bundled. As a result, Babel 6 dependencies will no longer be deduplicated for npm2 users, so an nwb install will be slower and larger - consider upgrading to npm3 or yarn if you can.
- Removed support for deprecated
webpack.pluginsconfig innwb.config.js- this config must now be moved up intowebpackinstead.
Changed:
- Handling of
.svgfiles has been moved from thegraphicsloader to the newsvgloader so inlining can be configured separately. This matters if you're using a sprite system, as base64 inlining SVGs breaks fragment identifiers. - Changed
babel-plugin-transform-runtimeconfiguration to make use of newmoduleNameconfig; Webpack module resolution no longer uses a blanket fallback to nwb'snode_modules/for serving and builds. webpack.uglifyconfig can now be set tofalseto disable use ofUglifyJSPluginin production builds for debugging [#160]
Dependencies:
- autoprefixer: v6.4.0 → v6.5.3
- babel-cli: v6.11.4 → v6.18.0
- babel-core: v6.13.2 → v6.20.0
- babel-loader: v6.2.4 → v6.2.9 - better syntax error messages
- babel-plugin-istanbul: v2.0.0 → v3.0.0
- babel-plugin-lodash: v3.2.8 → v3.2.10
- babel-plugin-transform-react-remove-prop-types: v0.2.9 → v0.2.11
- babel-plugin-transform-runtime: v6.12.0 → v6.15.0 - add
moduleNameconfig to specify runtime path - babel-polyfill: v6.13.0 → v6.20.0
- babel-preset-es2015: v6.14.0 → v6.18.0
- babel-preset-es2016: v6.11.3 → v6.16.0
- babel-preset-react: v6.11.1 → v6.16.0
- babel-preset-stage-0: v6.5.0 → v6.16.0
- babel-preset-stage-1: v6.13.0 → v6.16.0
- babel-preset-stage-2: v6.13.0 → v6.18.0
- babel-preset-stage-3: v6.11.0 → v6.17.0
- babel-runtime: v6.11.6 → v6.20.0
- case-sensitive-paths-webpack-plugin: v1.1.3 → v1.1.4 - handle cwd being incorrect case
- copy-webpack-plugin: v3.0.1 → v4.0.1
- css-loader: v0.23.1 → v0.26.1 - cssnano's use of autoprefixer is now disabled by default
- detect-port: v1.0.0 → v1.0.6
- diff: v2.2.3 → v3.1.0
- figures: v1.7.0 → v2.0.0
- html-webpack-plugin: v2.22.0 → v2.24.1
- inquirer: v1.1.2 → v2.0.0
- glob: v7.0.5 → v7.1.1
- karma: v1.2.0 → v1.3.0
- karma-chrome-launcher: v1.0.1 → v2.0.0 - chromium support
- karma-mocha: v1.1.1 → v1.3.0
- karma-mocha-reporter: v2.1.0 → v2.2.1
- karma-phantomjs-launcher: v1.0.1 → v1.0.2 - fix phantomjs path calculation
- mocha: v3.0.2 → v3.2.0
- phantomjs-prebuilt: v2.1.12 → v2.1.13
- postcss-loader: v0.10.0 → v1.2.0
- qs: v6.2.1 → v6.3.0
- webpack: v1.13.1 → v1.14.0 - updated node-libs-browser and uglifyjs versions -
screw_ie8is now enabled by default; fix for Babel sourcemap issue - webpack-merge: v0.14.1 → v1.0.2
- webpack-dev-middleware: v1.6.1 → v1.8.4
- webpack-hot-middleware: v2.12.2 → v2.13.2
- whatwg-fetch: v1.0.0 → v2.0.1 - changes behaviour of
Headersto be spec-compliant
Removed:
- Dropped the production
react-constant-elementstransform for now due to bugs.
Experimental:
react runcan now run modules which export a React component or element.
Added:
- Added a
reloadoption to Express middleware to enable reloading the page if Hot Module Reloading is unsuccessful [#168]
Breaking Changes:
-
Dropped Node.js v0.12 support
Based on the
enginesconfig of nwb's dependencies, Node.js v4.2.0 is now the minimum required version. -
Upgraded from Babel 5 to Babel 6 [#12] [#31] [@geowarin]
Babel 6 introduced a number of breaking changes which you may need to account for in your codebase if you're using nwb or were otherwise using Babel 5.
babelconfig innwb.config.jsis no longer directly equivalent to what you would put in a.babelrcfile. -
Added support for long-term caching [#73]
A deterministic hash is now included in the filenames of generated
.jsand.cssfiles.The Webpack manifest (required for module loading) is now extracted and automatically injected prior to the
</body>tag, so your HTML template must have a</body>tag.If you do any post-build processing on generated files it might need to be updated, as production app builds will now generate files as
[name].[hash].[ext]instead of[name].[ext]. -
Dropped support for the
.jsxextensionYou can use
webpack.loadersconfig to set/\.jsx?$/asbabel-loader'stestconfig andwebpack.extra configto add.jsxback to theresolve.extensionslist if you're using.jsxfiles and can't reasonably migrate away. -
Dropped
build-moduleandbuild-umd/clean-umdcommandsThese were a confusing middle layer which split the implementation of building a React component or browser-focused npm module in two. They both required a config file to provide a project
typefor nwb to figure out what to do.They've been replaced with
build-react-componentandbuild-web-modulecommands, which are now used inpackage.jsonscriptsin the corresponding project skeletons.As a result having a config file is now optional for all project types. If you don't need configuration, you can delete the
nwb.config.jsfile created as a convenience by project skeletons.A config file is now only required if you want to use the generic
build,cleanandservecommands. -
Changed ES6 module build directory from
es6/toes/Upgrade steps:
- Replace
"es6/index.js"with"es/index.js"inpackage.json"jsnext:main"config - Also add
"module": "es/index.js", as this is part of a proposal for native module support which is being supported by multiple bundlers. - Replace
"es6"with"es"inpackage.jsonfilesconfig
- Replace
-
Dropped
webpack.vendorBundleconfig in favour of a--no-vendorflagMaking this feature toggle a command line argument makes it easier to try, and to combine with other feature toggles like
--preact.Tweak your
package.json"build"script instead if you were usingwebpack.vendorBundle: falseconfig:{ "scripts": { "build": "nwb build-react-app --no-vendor" } }
nwb.config.js Config Format Changes:
-
buildconfig is deprecated in favour of newnpmconfig, which is a slightly different format.nwb will adapt any
buildconfig it finds for the current build and log out the equivalentnpmconfig.// < v0.12 // v0.12 module.exports = { module.exports = { build: { => npm: { jsNext: true, esModules: true, umd: true, => umd: { global: 'MyComponent', global: 'MyComponent', externals: {'react': 'React'} externals: {'react': 'React'} } } } } }// < v0.12 // v0.12 - simple UMD config without externals module.exports = { module.exports = { build: { => npm: { jsNext: true, esModules: true, umd: true, => umd: 'myLib' global: 'MyLib' } } } } -
The Babel runtime transform is now configured using new
babel.runtimeconfig instead of Babel 5'soptionalconfig.The runtime transform is now partially-enabled by default to support use of
async/awaitand generators, so update your configuration accordingly. nwb will adapt['runtime']config for the current build by converting it totrue.// < v0.12 // v0.12 - enabled by default for regenerator module.exports = { babel: { optional: ['runtime'] => // You can remove your config if you were } // using it for async/await or generators }// < v0.12 // v0.12 - also import helpers from module.exports = { module.exports = { babel: { babel: { optional: ['runtime'] => runtime: 'helpers' } } } } -
babel.looseconfig is now Boolean instead of Babel 5's string config.
Loose mode is now enabled by default, so loose config is only used if you need to disable loose mode.
// < v0.12 // v0.12 - enabled by default
module.exports = {
babel: {
loose: 'all' => (none)
}
}
// < v0.12 - loose mode not used // v0.12 - disabling loose mode
module.exports = {
babel: {
(none) => loose: false
}
}
-
karma.testsconfig is deprecated in favour of newkarma.testContextandkarma.testFilesconfig, depending on which was being specified. Ifkarma.testsis present, nwb will attempt to detect the appropriate new config to use it for, or will otherwise fall back to the new default config.// < v0.12 // v0.12 - using a Webpack context module module.exports = { module.exports = { karma: { karma: { tests: 'tests.webpack.js' => testContext: 'tests.webpack.js' } } } }// < v0.12 // v0.12 - custom test file glob module.exports = { module.exports = { karma: { karma: { tests: 'test/**.test.js' => testFiles: 'test/**.test.js' } } } }
Developer Experience Improvements:
-
Added a
check-configcommand which checks your nwb configuration file for errors and deprecated usage, and provides some usage hints (e.g. where more convenient config is available).Run this after upgrading your nwb version and it will tell you what needs to be changed.
-
New user-friendly output for Webpack builds based on create-react-app's.
This provides friendlier error and warning reporting, reports the gzipped size of generated files and uses a persistent console for development server logging.
Windows Note: running a development server will clear the current screen in your console - in Windows the escape codes used to do this have the unfortunate effect of clearing all the scrollback history in your current console.
To avoid this use the
startcommand to spawn a new command window when running the development server in Windows, e.g.:start npm start start react run app.js -
Apps can now use
fetch,async/awaitand generators out of the box without any configuration.Promise,fetch,Object.assignpolyfills and the regenerator runtime are now provided by default. -
You can now transform destructured imports to cherry-picked imports for specified modules using new
babel.cherryPickconfig [#141] -
Case-sensitivity of
require/importpaths is now enforced byCaseSensitivePathsPlugin, avoiding an easy-to-overlook cause of CI build failure if you don't develop on Linux. -
If the intended dev server port is not available, you will now be prompted to continue with a different, free port.
React App Optimisations:
-
Production React builds now remove
propTypesfrom ES6 class and stateless functional components (but not from your dependencies) using react-remove-prop-types [#97] -
Added a
--preactflag to React app builds to create a preact-compat build.This is an easy way to try Preact with your React apps, resulting in a much smaller bundle if your app is compatible [#124]
Babel:
-
nwb implements its own support for a Babel 6 equivalent of Babel 5's
stageconfiguration to choose which experimental features are enabled, including defaulting to Stage 2.For stage 2 and below, decorators can be use by default, as nwb will include the Babel Legacy Decorator transform plugin. See the plugin's Best Effort documentation for differences you will need to take into account if you were using Babel 5 decorators.
-
nwb preserves CommonJS interop for apps and component ES5 builds using the
add-module-exportsplugin.This means a
.defaultdoesn't need to be tagged on when you're usingrequire()with Webpack's code-splitting, or when people import your npm modules usingrequire()directly.Babel 6 removed interop with CommonJS exports, as it allowed you to write broken ES6 code. Kent C. Dodds has a post about this which is well worth reading to understand what not to do.
-
Loose mode is now enabled by default.
-
Changed
babel.looseconfig to Boolean.This is now only needed if you want to disable loose mode (e.g. in non-production environments to check for ES6 compliance errors in normal mode).
-
Added
babel.runtimeconfig to configure the Babel runtime transform, replacing Babel 5'soptionalconfig.This is turned on by default, configured to import the regenerator runtime when
async/awaitor generators are used. -
Removed the inline element transform optimisation for React app production builds, as the Babel 6 version of it currently depends on polyfilling
Symbol.
Karma:
-
Changed default testing configuration to support co-location of tests and a wider range of test file names and locations. This should be backwards-compatible with the previous defaults.
- Test files included by default are now
-test.js,.test.jsor.spec.jsfiles anywhere underneath asrc/,test/ortests/directory. - Code coverage also ignores all code underneath
test/,tests/or any__tests__/directory insidesrc/by default, as well as test files.
- Test files included by default are now
-
Added
karma.browsersconfig to customise which browsers tests are run in.The plugin to support use of
'Chrome'in this config is also available by default. -
Added
karma.testDirsconfig to control which directories are excluded from code coverage reporting. -
babel-plugin-istanbulis now used to instrument code for test coverage instead ofisparta-loader.
Webpack:
Default Loader Config
- Disabled
css-loader's use of Autoprefixer - nwb's PostCSS configuration is now the only source of prefix addition and removal [#132] - All static file loaders now use
url-loader(which falls back tofile-loader) to allow you to configure inlining for any group of static files if needed. - Changed default
limitconfig for all static file loaders to1, effectively disabling inlining by default - if you want resources smaller than a given size to be inlined, configurelimitusingwebpack.loadersconfig. - Moved handling of
.svgfiles from thefontsloader to thegraphicsloader. - Moved handling of
.eotfiles to thefontsloader and removed theeotloader. - Added a
videoloader for.mp4',.oggand.webm. - Added
.webpto thegraphicsloader.
Default Plugin Config
- Updated default
UglifyJsPluginoptions to strip comments from output and use thescrew_ie8setting in every minification step.
Configuration
- Added
webpack.aliasesconfig to set up module resolving aliases, as a convenient alternative to usingwebpack.extra.resolve.alias[#125] - Added
webpack.autoprefixerconfig to configure Autoprefixer in nwb's default PostCSS configuration [#132] - Added
webpack.publicPathconfig to set up or clear the path/URL used for static resources, as a convenient alternative to usingwebpack.extra.output.publicPath. - Added
webpack.uglifyconfig to allow customisation of WebpackUglifyJsPluginoptions. webpack.compatconfig now supports'json-schema': trueto prevent a transitivejson-schemadependency breaking Webpack builds. This usually manifests itself as anUncaught Error: define cannot be used indirecterror.- Generated
module.noParseconfig is now anArray, so any user-provided config for it inwebpack.extra(which should also be specified as anArray) can now be merged into it.
npm Build:
-
When creating a project with an ES6 modules build enabled, a
"module"property will be added to the project'spackage.jsonas well as"jsnext:main"[#137]This is the default property Webpack 2 uses to look for an ES6 modules build.
-
buildconfig is deprecated in favour of newnpmconfig. -
React component builds now wrap
propTypesfor ES6 class and stateless functional components with an environment check -if (process.env.NODE_ENV !== 'production')- so they'll automatically be stripped from the production build in apps which use them. [#145]propTypeswill be stripped from the minified UMD build.This can be disabled by passing a
--no-proptypesflag. -
Building a React demo app during a React component build can now be skipped by passing a
--no-demoflag [#155]
Other Configuration:
- Fallback index serving for HTML5 History apps is now enabled by default in the development server. This can be disabled by passing a
--no-fallbackflag. - Added
polyfillconfig to disable default polyfilling ofPromiseandfetchfor apps if you don't need it and want to shave a few KB off your build. - The dev server port can now be specified via a
PORTenvironment variable. The CLI--porttakes precedence if both are provided.
CLI:
- Added a
nwb check-configcommand. - CLI now uses spinners for build commands, with gzipped filesize logging.
- Reworked build commands for React components and npm modules to remove a needless middle layer and add specific build commands for these project types.
- Removed the
-g, --globalargument for enabling a UMD build when creating a React component or web module project, in favour of passing a name to the--umdargument instead. - Removed the
--infoflag for showing webpack output, as this is now handled in a more developer-friendly manner.
Starter Projects:
- The react-app project skeleton now includes examples of importing CSS and images.
- Required
<meta>tags in HTML templates are now all first thing in<head>. - Added
shrink-to-fit=noto theviewport<meta>tag in HTML templates for Safari.
Dependencies:
- autoprefixer: v6.3.6 → v6.4.0
- babel* v5 → babel* v6
- babel-plugin-istanbul: v2.0.0
- babel-plugin-lodash: v3.2.8
- babel-plugin-transform-react-remove-prop-types: v0.2.9
- case-sensitive-paths-webpack-plugin: v1.1.3
- connect-history-api-fallback: v1.2.0 → v1.3.0 - allow disabling of the dot rule
- copy-template-dir: v1.2.1 → v1.3.0 - support vars in filenames
- expect: v1.20.1 → v1.20.2
- express: v4.13.4 → v4.14.0
- figures: v1.7.0
- file-loader: v0.8.5 → v0.9.0
- glob: v7.0.3 → v7.0.5
- html-webpack-plugin: v2.19.0 → v2.22.0
- inquirer: v1.0.3 → v1.1.2
- karma: v0.13.22 → v1.2.0
- karma-chrome-launcher v1.0.1
- karma-coverage: v1.0.0 → v1.1.1
- karma-mocha-reporter: v2.0.3 → v2.1.0
- karma-phantomjs-launcher: v1.0.0 → v1.0.1
- karma-webpack: v1.7.0 → v1.8.0 - remove dist from scm
- mocha: v2.5.3 → v3.0.2
- npm-install-webpack-plugin: v4.0.1 → v4.0.4
- phantomjs-prebuilt: v2.1.7 → v2.1.12 - npm packaging fun
- postcss-loader: : v0.9.1 → v0.10.0
- qs: v6.2.0 → v6.2.1
- rimraf: v2.5.2 → v2.5.3
- webpack-fail-plugin: v1.0.5
- webpack-hot-middleware: v2.10.0 → v2.12.2
- webpack-md5-hash: v0.0.5
- webpack-merge: v0.14.0 → v0.14.1
Fixed:
- PostCSS config was not being created for the vendor/
node_modules/loader for CSS preprocessor plugins [#129]
Breaking Changes:
- Replaced the deprecated
autoprefixer-loaderwithpostcss-loaderin default style pipelines - it's configured to do the same autoprefixing by default [#57]- If you were configuring vendor prefixing using
webpack.loaders.autoprefixer, you will now need to manage anautprefixerdependency yourself and usewebpack.postcssto perform this configuration.
- If you were configuring vendor prefixing using
nwb.config.js Config Format Changes:
-
webpack.pluginsis deprecated - config underwebpack.pluginsshould be moved up intowebpackinstead. Having certain config under apluginsprop was an implementation detail which wasn't relevant to end-users [#113]// < v0.11 module.exports = { webpack: { plugins: { define: {...}, html: {...} } } }
// v0.11 module.exports = { webpack: { define: {...}, html: {...} } }
-
Support for flatter Webpack loader configuration was added. Having a
queryobject is now optional - loader query configuration can now be placed directly under the loader's id [#113]// < v0.11 module.exports = { webpack: { loaders: { css: { query: { modules: true } } } } }
// v0.11 module.exports = { webpack: { loaders: { css: { modules: true } } } }
Added:
- Installing globally now adds a
reactcommand for quick React development starting from a single file.react run entry.jsruns a development server.react build entry.jscreates a static build.- For these commands, Babel is preconfigured to allow you to use all of its Stage 0 features out of the box, including
async/await. - These are implemented by (the previously undocumented)
serve-reactand (new)build-reactnwb commands.
- The entry point for apps and npm module UMD builds can now be specified as an argument to
buildandservecommands. The default is stillsrc/index.js. [#115] - The directory web apps are built into can now be specified as an argument to
build,cleanandservecommands. The default is stilldist/. - Added
webpack.compatconfig to enable compatibility tweaks for modules which are known to be problematic with Webpack - initially this includes support for Enzyme, Moment.js and Sinon.js 1.x [#108] - Added
webpack.postcssconfig to customise the PostCSS plugins applied to each style pipeline [#57] - Added
webpack.vendorBundleconfig to disable automatically extracting anything imported fromnode_modules/out into a separatevendorchunk [#106] - Added documentation for creating and using a test context module if there's code you need to run prior to tests running, such as configuring your assertion library with additional assertions.
- Added a
--configoption to allow you to specify your own config file instead ofnwb.config.js.
Changed:
- Apps are no longer required to provide their own HTML template. The default template path of
src/index.htmlwill continue to be used if a file exists there. If an alternative template is not provided viawebpack.htmlconfig, nwb will now fall back to using a basic template. - Restored default use of the Babel polyfill in Karma config so tests (and their dependencies) can assume a modern environment.
- Default
babel-loaderconfig now usescacheDirectory: truefor a speedup. - Improved debug output (activated with a
DEBUG=nwbenvironment variable) to print config objects in full - if you're configuring plugin objects (e.g. PostCSS plugins), it's recommended to create instances of them if you want to use debug output. webpack.optimize.DedupePluginis now only used for production builds, as recommended in the Webpack docs.
Dependencies:
- diff: v2.2.2 → v2.2.3
- html-webpack-plugin: v2.17.0 → v2.19.0
- inquirer: v1.0.2 → v1.0.3
- mocha: v2.4.5 → v2.5.3
- npm-install-webpack-plugin: v3.1.2 → v4.0.1 - saving is on by default and a new
devoption controls where installed dependencies get saved to - postcss-loader: v0.9.1
- redbox-noreact: v1.0.0 → v1.1.0
- webpack: v1.13.0 → v1.13.1
- webpack-merge: v0.12.0 → v0.14.0
Breaking Changes:
- React v15 is now installed into React app/component skeletons by default.
Changed:
- Default Karma config now includes
showDiff: trueconfig for the default Mocha reporter. - The dev server now logs an initial
webpack building...message so you know you're waiting for the initial build. - npm scripts in the skeletons generated for
react-appandweb-appprojects now use project type-specific commands, so thenwb.config.jsincluded with them can be deleted if you don't need any config tweaks. - nwb now passes the
--saveoption to npm when installing React dependencies, to honour any npm save-exact (recommended!) or save-prefix config you have set.
Added:
- Extra Karma config can now be configured via a
karma.extraObject. - Added a
--reactoption to allow you to set the version of React which will be installed when creating apps or components. This defaults to whatever the stable version of React was when the version ofnwbyou're using was released.
Dependencies:
- chalk: v1.1.1 → v1.1.3 - update deps
- cross-spawn: v2.1.5 → v2.2.3 - update deps
- detect-port: v1.0.0
- expect: v1.16.0 → v1.20.1
- fs-extra: v0.26.7 → v0.30.0
- html-webpack-plugin: v2.14.0 → v2.17.0
- inquirer: v0.12.0 → v1.0.2 - switch to Promise-based API
- karma-coverage: v0.5.5 → v1.0.0
- karma-mocha: v0.2.2 → v1.0.1
- karma-mocha-reporter: v2.0.0 → v2.0.3
- npm-install-webpack-plugin: v3.0.0 → v3.1.2 [#77]
- phantomjs-prebuilt: v2.1.6 → v2.1.7
- qs: v6.1.0 → v6.2.0
- webpack: v1.12.14 → v1.13.0
- webpack-merge: v0.8.4 → v0.12.0
Dependencies:
- webpack-dev-middleware: v1.6.0 → v1.6.1 - fixes request path issue introduced in 1.6.0
Fixed:
style-loaderwas not being specified to apply styles from additional chunks when extracting CSS.
Breaking Changes:
- Changes to how React and plain JS web apps are built:
-
Builds are now generated in
dist/instead ofpublic/build/ -
index.htmlfor builds is now generated based on a template insrc/index.html, instead of using a staticpublic/index.html[#34]Upgrading existing projects:
- move your
public/index.htmltosrc/index.htmland delete the<link>and<script>tags forvendorandappresources. These will now be injected at build time. - replace
/public/buildin your.gitignorewith/dist/
- move your
-
public/is now only for public files - any contents in this directory will now be copied todist/at the start of a build. The development server will also serve static content frompublic/.
-
Removed:
- Backwards compatibility for
nwb.config.jsformat changes made in 0.8 has been removed.
Added:
- Added a
--hostoption when running the dev server [#50] ExtractTextPlugin(used to extract CSS when building) can now be configured usingwebpack.plugins.extractTextconfig - this allows you to configure theallChunkssetting if you want all CSS to be extracted when using code splitting.HtmlWebpackPlugin(used to generate anindex.htmlwhen building) can now be configured usingwebpack.plugins.htmlconfig.
Changed:
breakConfig: truehas been added to defaultbabel-loaderconfig to avoid.babelrcfiles being resolved by Babel - all Babel configuration is expected to be innwb.config.js[#63]- Static resources handled by Webpack's
file-loadernow include a hash in their filenames for cachebusting when they change [#38]
Dependencies:
- babel: v5.8.34 → v5.8.38 - left-pad transitive dependency drama
- babel-core: v5.8.34 → v5.8.38 - left-pad transitive dependency drama
- connect-history-api-fallback: v1.1.0 → v1.2.0 - support custom
Acceptheaders - copy-template-dir: v1.2.0 → v1.2.1 - support large template folders
- expect: v1.14.0 → v1.16.0 - mostly packaging changes?
- fs-extra: v0.26.5 → 0.26.7 - bug fixes for
copyandemptyDir - glob: v7.0.0 → v7.0.3 - misc fixes
- html-webpack-plugin: v2.9.0 → v2.14.0
- karma: v0.13.21 → v0.13.22 - removed a large test file from npm package
- karma-coverage: v0.5.3 → v0.5.5 - bug fixes
- karma-mocha-reporter: v1.2.3 → v2.0.0 - add karma to peerDeps; wait for all browsers to run
- npm-install-webpack-plugin: v2.0.2 → v3.0.0 -
resolve.aliasandresolve.rootsupport [#83] - phantomjs-prebuilt: v2.1.4 → v2.1.6 - minor fixes to custom CA handling
- react-transform-hmr: v1.0.2 → v1.0.4 - update react-proxy to fix a few correctness issues
- style-loader: v0.13.0 → v0.13.1 - add query to style/useable
- webpack-dev-middleware: v1.5.1 → v1.6.0
- webpack-hot-middleware: v2.7.1 → v2.10.0 - improved error overlay styling
- webpack-merge: v0.7.3 → v0.8.4 - change merging behavior so only loaders get prepended
Dependencies:
- karma-mocha-reporter: v1.2.2 → v1.2.3 - don't fail test suites containing skipped tests
Breaking Changes:
-
npm-install-webpack-pluginis now used instead ofnpm-install-loaderto implementnwb serve --auto-install.If you were configuring automatic npm installation using a
loaders.install.query.cliconfig object, this should be moved towebpack.plugins.installinstead.
nwb.config.js Config Format Changes:
-
React component and vanilla JS module npm build configuration must now be specificed as a
buildobject:// < v0.9 module.exports = { type: 'react-component', externals: {react: 'React'}, global: 'MyComponent', jsNext: true, umd: true }
// v0.9 module.exports = { type: 'react-component', build: { externals: {react: 'React'}, global: 'MyComponent', jsNext: true, umd: true } }
-
Webpack configuration must now be specified as a
webpackobject:// < v0.9 module.exports = { type: 'react-app', loaders: { css: { query: { modules: true } } } }
// v0.9 module.exports = { type: 'react-app', webpack: { loaders: { css: { query: { modules: true } } } } }
-
Webpack
defineconfig must now be specified in apluginsobject:// < v0.9 module.exports = { type: 'react-app', define: { __VERSION__: JSON.stringify(require('./package.json').version) } }
// v0.9 module.exports = { type: 'react-app', webpack: { plugins: { define: { __VERSION__: JSON.stringify(require('./package.json').version) } } } }
-
All "extra" Webpack config must be specified in a an
extraobject, including extra loaders. The new object must correspond with Webpack's config file layout.// < v0.9 module.exports = { type: 'react-app', loaders: { extra: [/* ... */] } }
// v0.9 module.exports = { type: 'react-app', webpack: { extra: { module: { loaders: [/* ... */] } } } }
Changes:
nwb.config.jsis now only required when running generic build commands:build,clean,serve,testtypeconfig is only required when running a generic build command, but if provided it must be valid.
- Karma tests now always run just once in a CI environment regardless of the
--serverflag - this allows you to use--serverin your defaultnpm testcommand if you want to, without needing a separate run script for CI. - Development instructions in project skeletons were moved from
README.mdto aCONTRIBUTING.mdfile, and are now documented usingnpmandnpm runcommands instead of globalnwbcommands. - All commands are now run in the current working directory - you no longer need to
require.resolve()full paths to extra Babel plugins configured innwb.config.js, just use their names as normal and Babel will now be able to import them. - Upgraded to PhantomJS v2 for Karma tests.
- Babel polyfills are no longer included in Webpack config for Karma, as PhantomJS v2 uses a more recent version of WebKit.
Added:
- Extra webpack config can now be configured via a
webpack.extraObject.- To support adding other webpack built-in plugins via
extra, if a function is exported fromnwb.config.js, it will now be called with an object containing the following properties:command- the nwb command being executedwebpack- the webpack module (for configuring extra plugins using nwb's version of webpack)
- To support adding other webpack built-in plugins via
- Project type-specific versions of the
build,cleanandservecommands are now officially documented for direct use. - A
test:watchnpm script was added to project templatepackage.json.
Dependencies:
- autoprefixer-loader: v3.1.0 → v3.2.0
- cross-spawn: v2.1.4 → v2.1.5 - update
whichdependency (minor) - expect: v1.13.4 → v1.14.0 - new features
- express: v4.13.3 → v4.13.4 - deps
- extract-text-webpack-plugin: v0.9.1 → v1.0.1 - use webpack-sources
- glob: v6.0.3 → v7.0.0 - throw if cwd is not a directory
- html-webpack-plugin: v1.7.0 → v2.9.0
- inquirer: v0.11.2 → v0.12.0
- karma: v0.13.18 → v0.13.21 - socket.io 1.4.5 seems to have fixed the post-test hanging issue, bug fixes and new features
- karma-mocha: v0.2.1 → v0.2.2
- karma-mocha-reporter: v1.1.5 → v1.2.2 - add diff output for failed tests
- karma-phantomjs-launcher: v0.2.3 → v1.0.0 - use phantomjs-prebuild
- mocha: v2.3.4 → v2.4.5
- phantomjs v1.9.19 → phantomjs-prebuilt v2.1.4 - update installer to PhantomJS 2.x, renamed package
- qs: v5.2.0 → v6.1.0 - revert ES6 requirement, new
allowDotsoption and some fixes - react-transform-catch-errors: v1.0.1 → v1.0.2 - remove some files from the npm package
- react-transform-hmr: v1.0.1 → v1.0.2 - remove some files from the npm package
- resolve: v1.1.6 → v1.1.7 - fix
node_modulespaths on Windows - rimraf: v2.5.0 → v2.5.2
- webpack: v1.12.11 → v1.12.14 - fix Windows filename backslash incompatibility
- webpack-dev-middleware: v1.4.0 → v1.5.1 - platform-agnostic path joining, use
res.sendwhen available - webpack-hot-middleware: v2.6.0 → v2.7.1 - improve hint when hot reloads aren't accepted, update
strip-ansidependency (major), update stats handling
Fixed:
react-appandweb-appWebpack build config didn't haveoutput.publicPathset, so images required from JavaScript weren't being found [#55]- Test runs no longer hang for up to a minute after completion [#49]
Dependencies:
- inquirer: v0.11.1 → v0.11.2 - display fixes
- karma: v0.13.19 → v0.13.18 - downgraded due to the test hanging issue being introduced
- karma-sourcemap-loader: v0.3.6 → v0.3.7 - avoid EMFILE errors; fix charset bug; fix RangeError exception
- socket.io: v1.3.7 - temporarily pinned in nwb's dependencies until the Karma test hang issue is resolved
- webpack: v1.12.10 → v1.12.11
- webpack-merge: v0.7.2 → v0.7.3 - bugfix
Fixed:
- Express middleware had a broken import.
Added:
- Added an
autoInstalloption to Express middleware.
Dependencies:
- glob: v6.0.3 → v6.0.4 - remove
util._extendto avoid deprecation warnings - karma: v0.13.18 → v0.13.19 - handle new socket.io internal format
- webpack: v1.12.9 → v1.12.10
- webpack-merge: v0.7.1 → v0.7.2 - fix inclusion of removed
changelogdependency
Fixed:
- Fall back to nwb's dependencies in Webpack config instead of using an alias so
babel-runtimecan be picked up whenoptional: ['runtime']is used [hopefully fixing the weird/node_modules/node_modules/issue seen in [#37]
Added:
- Added an
--auto-installflag tonwb servewhich automatically installs npm dependencies and saves them to your package.json while developing.
Removed:
jsNextconfig no longer defaults totrueif not present.
Changed:
- Use
.xfor dependencies when generating skeleton projectpackage.jsoninstead of range sigils.
Dependencies:
- babel-runtime: v5.8.34 → v5.8.29 - downgraded due to a regression in typeof-react-element.js when used in conjunction with
optional: ['runtime'] - karma: v0.13.16 → v0.13.18
- karma-phantomjs-launcher: v0.2.2 → v0.2.3 - correct cli argument order
- webpack-merge: v0.7.0 → v0.7.1 - performance improvements
Fixed:
nwb build-umdno longer errors if there is noexternalsconfig.
Changed:
nwb cleannow deletes thecoverage/directory.
Dependencies:
- inquirer: v0.11.0 → v0.11.1 - fix list overflow bug
Fixed:
- Exit the process correctly with a non-zero exit code when an async command fails, such as
nwb test[#36] [jihchi]
Dependencies:
- karma-mocha-reporter: v1.1.4 → v1.1.5 - show error message when karma runner ends with error
- webpack-merge: v0.5.1 → v0.7.0 - bug fix for merging arrays within nested structures
Dependencies:
- argv-set-env: v1.0.0 → v1.0.1 - docs
- glob: v6.0.1 → v6.0.3 - v6.0.2 was reverted
- karma: v0.13.15 → v0.13.16
- karma-mocha-reporter: v1.1.3 → v1.1.4 - handle duplicate descriptions
- karma-phantomjs-launcher: v0.2.1 → v0.2.2
- react-transform-catch-errors: v1.0.0 → v1.0.1 - display the offending call stack more prominently
- rimraf: v2.4.5 → v2.5.0 - add glob option
- webpack-merge: v0.3.2 → v0.5.1 - fix recursive merging
Fixed:
- The
es6/directory wasn't included in the default.gitignorefor npm module project skeletons.
Added:
- Added an
nwb initcommand - same asnwb newbut creates a project in the current directory and uses the directory name by default [#25] - Added a new
web-appproject type - this is for anyone who wants to use nwb's build/serve/test setup but isn't using React [#24] - Added a
--reloadoption to auto-reload the page when webpack hot module replacement gets stuck. This is primarily intended for use with the newweb-appproject type. - Command-line arguments can now be used to configure settings for
nwb new.
Fixed:
- Production optimisations weren't being applied to React app builds.
- Demo apps weren't generating sourcemaps when bundling.
- Use a non-zero exit code when displaying usage or otherwise exiting due to missing arguments [#23]
Changed:
- Reorganised and coloured
nwb helpoutput. - Commands which create files now log details of what they've created [#26]
- The ES6 modules build for npm modules is now optional, controlled by a
jsNextsetting innwb.config.js, defaulting totrue[#27]- nwb 0.6 will default
jsNexttotrueand log a warning when it's missing from a config file - this behaviour will be removed in nwb v0.7.
- nwb 0.6 will default
Dependencies:
- copy-template-dir: v1.1.0 → v1.2.0 - provide created file paths in callback
- css-loader: v0.23.0 → v0.23.1
- expect: v1.13.3 → v1.13.4 - comparing arrays of nested objects fix
- rimraf: v2.4.4 → v2.4.5
Added:
- Top-level Webpack config can now be provided for loaders which support it, as a
configobject in theirnwb.config.jsloadersconfiguration. This is intended for loaders which can't use serialisablequeryconfig due to plugins, such as some CSS preprocessors [#18]
Fixed:
filesconfig from templatepackage.jsonwas being used when packing nwb for publishing. Renamed them to_package.jsonto avoid this [#22]
Changed:
- Downgraded qs dependency so nwb can be used with Node.js 0.12.x [#19]
Dependencies:
- copy-template-dir: v1.0.5 → v1.1.0 - rename all files beginning with
_ - expect: v1.13.0 → v1.13.3 -
Map,Setand circular comparison fixes - qs: v6.0.0 → v5.2.0 - downgrade to lose Node.js >= 4.0.0 requirement
Fixed:
- Bad npm package for 0.4.0 - npm was reading the new
filesconfig frompackage.jsonin templates for React component/web module skeletons and applying it when packing nwb itself for publishing [#21]
Added:
- Added
--fallbackoption tonwb serve, for serving the index page from any path when developing React apps which use the HTML5 History API [#16] - Added
"engines": {"node": ">=4.0.0"}topackage.json- nwb accidentally depends on this because it uses qs v6 [#19] - Added
filesconfig to React component/web module skeletonpackage.json.- The
filesconfig for the React component skeleton assumes that components published to npm withrequire()calls for CSS which ships with it will use acss/dir.
- The
- Added a default ES6 build with untranspiled ES6 module usage [#15]
- This is pointed to by
"jsnext:main"in project skeletonpackage.jsonfor use by tree-shaking ES6 bundlers.
- This is pointed to by
Fixed:
- Added missing
mainconfig to React component/web module skeletonpackage.json, pointing at the ES5 build inlib/. - Express middleware wasn't included in npm package.
Changed:
- 1.0.0 is now the default version for project skeletons.
Fixed:
- Generic
nwb buildwas broken for React components/web modules in 0.3.0.
Added:
- Support for CSS preprocessor plugin packages [#6]
Fixed:
- Babel config is now passed to Babel when transpiling modules [#13]
Added:
- Express middleware for running a React app on your own development server using nwb's Webpack config generation [#8]
Changed:
- Webpack loader config objects are now merged with webpack-merge; query objects will now be deep merged, with lists occurring at the same position in build and user config being concatenated instead of overwritten.
Fixed:
- babel-runtime can now be resolved from nwb's dependencies when using
optional: ['runtime']Babel config [#10] - Paths to resources required from CSS in React app builds [#9]
First 0.x release.