Commit graph

9507 commits

Author SHA1 Message Date
Katsuma Ito
2e51e1bb9b
[ESLint] Add add next/script support for no-unwanted-polyfillio rule (#28944)
Make the `no-unwanted-polyfillio` rule respond to the `next/script` component as well as the `script` tag.

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [x] ~Integration~Unit tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`
2021-10-22 11:19:24 +00:00
Tobias Koppers
0f453c06e2
improve CI stability (#30171) 2021-10-22 12:35:38 +02:00
Tobias Koppers
8a4d1f75f2
test and fix error reporting for stack overflows and other fatal errors (#30169)
## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `yarn lint`
2021-10-22 10:30:50 +00:00
JJ Kasper
67681fe097
Replace middleware flag with warning (#30160)
Follow-up to https://github.com/vercel/next.js/pull/30154 this replaces the experimental flag with a warning that is shown once on usage instead.
2021-10-22 06:40:57 +00:00
JJ Kasper
7e81d13a8e
Add experimental config for middleware (#30154)
* Add experimental config for middleware

* Apply suggestions from code review

Co-authored-by: Steven <steven@ceriously.com>

Co-authored-by: Steven <steven@ceriously.com>
2021-10-21 22:00:51 -05:00
jj@jjsweb.site
25908cf963
v11.1.3-canary.94 2021-10-21 20:38:20 -05:00
Steven
022675404b
Use default next.config.js if not found (#30155)
Some warnings/errors will mention `next.config.js` even if it doesn't exist so we'll make sure to assign a default value of `next.config.js`.

- Follow up to #30152
2021-10-22 01:18:57 +00:00
Steven
6f3e9470a6
Ensure error message prints next.config.mjs (#30152)
This PR ensures we print the correct error message for either `next.config.js` or `next.config.mjs`, whichever was detected.
2021-10-21 23:04:40 +00:00
JJ Kasper
97f0752e47
Update middleware chunk handling (#30151)
* Update middleware chunk handling

* fix lint
2021-10-21 17:00:26 -05:00
jj@jjsweb.site
208667a17a
v11.1.3-canary.93 2021-10-21 13:42:37 -05:00
JJ Kasper
1e2c4c4c00
Ensure we dont attempt minifying middleware-chunks (#30147)
Follow-up to https://github.com/vercel/next.js/pull/30122 this ensures we don't minify the accompanying `middleware-chunks` either.
2021-10-21 18:41:36 +00:00
Tim Neutkens
00fdb64da7 v11.1.3-canary.92 2021-10-21 16:59:15 +02:00
Donny/강동윤
15ad98de32
Update swc (#30141)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-21 16:47:05 +02:00
Tim Neutkens
581e28675c v11.1.3-canary.91 2021-10-21 15:55:07 +02:00
Tobias Koppers
d07107f2c6
add experimental.urlImports option (#30079)
Co-authored-by: Lee Robinson <me@leerob.io>
Co-authored-by: Rich Haines <hello@richardhaines.dev>
2021-10-21 13:14:57 +02:00
Tobias Koppers
be2156f634
fix pageKey and compiling output for on-demand-entries (#30116)
shows `compiling /_error...` instead of `compiling /next/dist/pages/_error...`
2021-10-21 10:52:50 +00:00
Tobias Koppers
8bce51d8a9
avoid showing empty Import trace for requested module (#30130)
## Bug

- [ ] Related issues linked using `fixes #number`
- [x] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `yarn lint`
2021-10-21 10:07:02 +00:00
Donny/강동윤
5f73633d4d
Update swc (#30127)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-21 08:31:36 +02:00
Maia Teegarden
282c1c9d7c
Fix creation of styled jsx ids (#30124)
Ids of dynamic styles now match ids in dynamic class names (`_JSXStyle.dynamic()`) when there are mixed styles (global/static).

## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes
2021-10-21 03:56:57 +00:00
jj@jjsweb.site
d87955e882
v11.1.3-canary.90 2021-10-20 22:11:58 -05:00
Katie Byers
58a79e34e5
add linting instructions (#30123) 2021-10-20 21:52:23 -05:00
JJ Kasper
0ac0b3f19f
Skip minifying middleware (#30122)
This skips minifying middleware as it can cause issues in some cases like the below error and also isn't necessary to be minified as we don't currently minify other server pages. 

```
TypeError: (intermediate value)(intermediate value)(intermediate value)(...) is not a function
```
2021-10-21 02:33:42 +00:00
Tobias Koppers
ecf2ee9c51
automatically enable managed paths for all node_modules (#30089)
This improves caching performance in monorepos where there are multiple node_modules folders
Automatically enable immutable paths for Yarn PnP
2021-10-21 01:25:45 +00:00
Roj
dd81d2c97e
Simplify export statement (#30015) 2021-10-21 00:31:14 +00:00
Tobias Koppers
b2a9918165
improve production error message printing (#30065)
* improve production error message printing

* update test cases

* add test case

* improve printing of build errors

* improve types

* fix test cases
2021-10-20 18:23:44 -05:00
Steven
094153f935
Fix repo-setup when .DS_Store exists (#30119) 2021-10-20 18:13:09 -05:00
Houssein Djirdeh
c8f25ba70b
adds temporary eslint v8 error (#30113) 2021-10-20 17:28:08 -05:00
jj@jjsweb.site
62895a8b29
v11.1.3-canary.89 2021-10-20 16:42:42 -05:00
Tobias Koppers
610d2b37c8
use xxhash64 by default (#30095)
Node.js 17 stopped supporting md4 as hash function

and we wanted to use a faster hash function anyway.

Fixes: https://github.com/vercel/next.js/issues/30078
2021-10-20 21:39:55 +00:00
Thibaut SABOT
3b34626fc8
docs: remove mention of experimental pageDataCollectionTimeout (#30107)
Removing the mention of `experimental.pageDataCollectionTimeout` in the docs as it doesn't exist anymore.

Related discussion: https://github.com/vercel/next.js/discussions/29992
2021-10-20 19:35:32 +00:00
JJ Kasper
f068319d4d
Enable shared worker pool by default (#30110) 2021-10-20 14:06:43 -05:00
Steven
dda14e7f4b
Add image example with background color using blurDataURL (#30111)
Demo: https://nextjs-examples-image-component-igy6n5cs1.vercel.sh/
2021-10-20 19:05:54 +00:00
Katie Byers
8fa5f34186
[examples] Fix deploy button URL in with-sentry example (#30112)
This updates the URL behind the "Deploy to Vercel" button in the readme of the `with-sentry` example. Changes which have been made:

- Addition of a required integration
- Removal of the required env var, as it's set by the integration

- [x] Make sure the linting passes
2021-10-20 18:21:12 +00:00
jj@jjsweb.site
7db5c9841e
v11.1.3-canary.88 2021-10-20 13:03:26 -05:00
Javi Velasco
a815ba9f79
Implement Middleware RFC (#30081)
This PR adds support for [Middleware as per RFC ](https://github.com/vercel/next.js/discussions/29750). 

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes
2021-10-20 17:52:11 +00:00
Tim Neutkens
157302d593 v11.1.3-canary.87 2021-10-20 16:16:51 +02:00
Tim Neutkens
78ce76553b
Enable fast refresh transform when using SWC (#30106) 2021-10-20 16:07:35 +02:00
Donny/강동윤
981348761b
Update swc (#30086)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-20 14:14:26 +02:00
Rishabh Poddar
6852efff45
Updating with-supertokens example (#29876)
Updating dependency of supertokens-node and providing development OAuth keys for google and github for quicker setup.
2021-10-20 07:00:16 +00:00
Steven
f2cf092ee6
Print error when images.loader is assigned but images.path is not (#30080)
Fixes #29744
2021-10-20 00:17:24 +00:00
Tobias Koppers
6f3dc0162f
update webpack (#30073)
https://github.com/webpack/webpack/releases/tag/v5.59.0

We need:
* experiments.buildHttp improvements for the new experimental flag
* managedPaths improvements from the monorepo improvements
* module build hooks for tracing
2021-10-19 21:03:12 +00:00
Steven
7439b976fc v11.1.3-canary.86 2021-10-19 13:29:37 -04:00
Steven
c4e26ab248
Prevent inherited styles on next/image wrapper or sizer (#30064)
As a follow up to #30041 which changed `<div>` to `<span>`, this PR makes sure that unexpected styles are not applied to the image wrapper or sizer spans.

For example: `.content span {}` would apply to all spans and incorrectly style the image wrapper.

This PR adds [`all: initial`](https://developer.mozilla.org/en-US/docs/Web/CSS/all) to effectively reset the span styles.
2021-10-19 17:16:17 +00:00
Donny/강동윤
f308b8a352
Update swc (#30066)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-19 17:50:07 +02:00
Tim Neutkens
3431214f02 v11.1.3-canary.85 2021-10-19 13:36:18 +02:00
Donny/강동윤
6f5ec2bd96
Update swc (#30057)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-19 13:34:54 +02:00
Donny/강동윤
caef3373da
Update swc (#30055)
Co-authored-by: kdy1 <kdy1@users.noreply.github.com>
2021-10-19 09:16:59 +02:00
jj@jjsweb.site
ab8e7dbfe2
v11.1.3-canary.84 2021-10-19 00:00:24 -05:00
Ionuț Botizan
d9bd329129
Sanitize the path to the user config before importing (#30003) 2021-10-18 22:46:11 -05:00
George Gach
ac287e67c1
Fixed Favicons URL mismatch across the project in [examples/blog-starter] (#29990)
## Bug
There is URL mismatch about the destination of favicons across the project in [examples/blog-starter](https://github.com/vercel/next.js/tree/canary/examples/blog-starter) i.e. `site.webmanifest` and `meta.js` are in a disagreement, triggering web app manifest initialization errors in Application tab of dev tools. ([relevant file](5edfbf276e/examples/blog-starter/public/favicon/site.webmanifest))

## Fix
This PR: 
1. Renames folder to plural `favicons`
2. Adjusts `favicons/*.png` urls in  `meta.js`
2021-10-19 03:37:44 +00:00