Skip to content

Commit

Permalink
Disable setImmediate polyfill (#10612)
Browse files Browse the repository at this point in the history
* Disable setImmediate polyfill

* Update size-limit

Co-authored-by: Joe Haddad <timer150@gmail.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
  • Loading branch information
3 people committed Feb 20, 2020
1 parent f0c8230 commit e9e1a2b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions packages/next/build/webpack-config.ts
Expand Up @@ -558,6 +558,9 @@ export default async function getBaseWebpackConfig(
].filter(Boolean),
},
context: dir,
node: {

This comment has been minimized.

Copy link
@cdierkens

cdierkens May 13, 2020

This is a breaking change. Why wouldn't this cause a major version?

setImmediate: false,
},
// Kept as function to be backwards compatible
entry: async () => {
return {
Expand Down
2 changes: 1 addition & 1 deletion test/integration/size-limit/test/index.test.js
Expand Up @@ -80,7 +80,7 @@ describe('Production response size', () => {
)

// These numbers are without gzip compression!
const delta = responseSizesBytes - 241 * 1024
const delta = responseSizesBytes - 238 * 1024
expect(delta).toBeLessThanOrEqual(1024) // don't increase size more than 1kb
expect(delta).toBeGreaterThanOrEqual(-1024) // don't decrease size more than 1kb without updating target
})
Expand Down

0 comments on commit e9e1a2b

Please sign in to comment.