* Pass config.experimental.cpus to export during build
Currently, there is no way of specifying the number of worker threads of
`next export` when run as part of `next build`.
I suggest a sane default should be to just use the same amount of
workers that were used during the build process which currently seems to
be configured through `config.experimental.cpus`.
This setting is already respected in the two other places where
jest-workers are in use: The TerserPlugin and the staticCheckWorkers in
`next build`.
* Only enable worker threads if there is more than 1 worker
Multiple worker threads can cause problems when certain dependencies are
being used, see e.g. https://github.com/zeit/next.js/issues/7894
This patch allows disabling of worker threads by setting
`config.experimental.cpus = 1`.
The benefit of spawning 1 worker thread, if there is any at all, should
very limited anyways, so the workload can just as well be processed in
the main thread.
* Disable parallel build for firebase authentication example
* Add integration test to cover #7894
* Rename test suite and add worker_threads config
* Disable worker_threads by default
* Update index.test.js
* Use workerThreads config for TerserPlugin
* Update to use workerThreads config in
TerserPlugin for consistency
* Disable node 12 specific test
* Add a configuration flag to disable integrated type checker
* Add tests for typescript-transpileonly
* Restore removed argument
* Make output more coherent
* Split transpileOnly into ignoreDevErrors and ignoreBuildErrors
* Minor stylistic change
* Add warning for getStaticParams without getStaticProps
* Throw error instead of logging to make sure it's noticed
* Lower default concurrency for tests
* allow NextScript to optionally defer javascript
* move defer options to experimental feature
* combine defer flags into a single option
* Update deferScripts to work with serverless target
* Add test for defer and async property
* Read the async property
* Check versions of chrome and chromedriver
* Update to chromedriver 76
* Fix test
Before this patch users would see the following warning during initial
compilation:
```
Warning: Each child in a list should have a unique "key" prop. See https://fb.me/react-warning-keys for more information.
in link
in Head
in html
in Html
in Document
in Context.Provider
in Context.Provider
```
* Ensure directory before flushing cache iSSG file
* Add test for prerender cache flush
* Nest the dynamic route test one more level
* update fetch for test
* Update error check
* Add tracking src dir usage to telemetry
* Move isSrcDir back to eventVersion
* Move spinner back
* Add test for isSrcDir telemetry
* Add test for dev mode
* Test `react(-dom)@canary` Every 12 Hours
* Use POSIX syntax
* Test
* Revert "Test"
This reverts commit ba5f22f0b0a2255613b8f11af84581722ad2ca7a.
* Print react versions prior to test
* Revert "Revert "Test""
This reverts commit 0b3cde3c4226066309561ca7c9e684070999af32.
* Revert "Revert "Revert "Test"""
This reverts commit c2c284a7a8d6dc9f39c6d16df109da3ed402afdf.
* add netlifycms example
* Updated everything
* Moved the layout out of _app
* Updated next to latest
* applied prettier and linter
* Removed unrequired files
* Moved to with-netlify-cms
* updated readme to reflect the new name
* Added license field
## Changelog
- Use functional components instead of class components
- Use default exports like in all other examples
- Rename `Portal` component to `ClientOnlyPortal`.