language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-slate/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-static-export/README.md | @@ -6,31 +6,10 @@ When trying to run `npm start` it will build and export your pages into the `out
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-stencil/README.md | @@ -8,8 +8,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [Yarn](https://yarnpkg.com/lang/en/docs/cli/create/) or [npx](https://github.com/zkat/npx#rea... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-stomp/README.md | @@ -8,35 +8,10 @@ Read more about [STOMP](http://jmesnil.net/stomp-websocket/doc/) protocol.
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/la... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-storybook/README.md | @@ -8,8 +8,6 @@ As of v6.0, Storybook has built-in TypeScript support, so no configuration is ne
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.co... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-strict-csp/README.md | @@ -13,8 +13,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-stripe-typescript/README.md | @@ -63,8 +63,6 @@ Once you have access to [the environment variables you'll need](#required-config
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-style-sheet/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-styled-components-rtl/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-styled-components/README.md | @@ -12,8 +12,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-styled-jsx-plugins/README.md | @@ -16,8 +16,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-styled-jsx-scss/README.md | @@ -16,8 +16,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-styletron/README.md | @@ -12,8 +12,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-tailwindcss-emotion/README.md | @@ -12,8 +12,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-tailwindcss/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-tesfy/README.md | @@ -18,8 +18,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-three-js/README.md | @@ -14,8 +14,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-typescript-eslint-jest/README.md | @@ -16,8 +16,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-typescript-graphql/README.md | @@ -25,8 +25,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-typescript-styled-components/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use it?
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/c... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-typescript/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use it?
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/c... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-typestyle/README.md | @@ -12,8 +12,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-unsplash/README.md | @@ -10,8 +10,6 @@ Once you have access to [the environment variables you'll need](#step-2-set-up-e
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-unstated/README.md | @@ -12,8 +12,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-urql/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com/now):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/c... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-userbase/README.md | @@ -12,8 +12,6 @@ Once you have access to [the environment variables you'll need](#step-2-setting-
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-videojs/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-web-worker/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com/):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/crea... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-webassembly/README.md | @@ -4,8 +4,6 @@ This example shows how to import WebAssembly files (`.wasm`) and use them inside
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.co... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-webpack-bundle-size-analyzer/README.md | @@ -4,8 +4,6 @@ This example shows how to analyze the output bundles using [webpack-bundle-size-
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.co... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-why-did-you-render/README.md | @@ -11,8 +11,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-xstate/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-yarn-workspaces/README.md | @@ -16,8 +16,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-zeit-fetch/README.md | @@ -10,8 +10,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | c03d4931debae938f1916c9ee85777a159d26371.json | Simplify example usage instructions (#16678)
Co-authored-by: Joe Haddad <joe.haddad@zeit.co> | examples/with-zones/README.md | @@ -15,8 +15,6 @@ Deploy the example using [Vercel](https://vercel.com):
## How to use
-### Using `create-next-app`
-
Execute [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app) with [npm](https://docs.npmjs.com/cli/init) or [Yarn](https://yarnpkg.com/lang/en/docs/cli/creat... | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/custom-server-typescript/package.json | @@ -18,6 +18,6 @@
"@types/react-dom": "^16.9.8",
"nodemon": "^2.0.4",
"ts-node": "^8.10.2",
- "typescript": "3.8.3"
+ "typescript": "4.0"
}
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-ant-design-pro-layout-less/package.json | @@ -25,6 +25,6 @@
"devDependencies": {
"@types/node": "13.13.4",
"@types/react": "^16.9.36",
- "typescript": "3.8.3"
+ "typescript": "4.0"
}
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-aws-amplify-typescript/package.json | @@ -22,6 +22,6 @@
"@types/node": "12.6.8",
"@types/react": "16.9.36",
"@types/react-dom": "16.9.8",
- "typescript": "3.9.5"
+ "typescript": "4.0"
}
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-expo-typescript/package.json | @@ -29,6 +29,6 @@
"@types/react-dom": "16.9.8",
"@types/react-native": "0.62.10",
"babel-preset-expo": "~8.1.0",
- "typescript": "3.9.3"
+ "typescript": "4.0"
}
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-react-intl/package.json | @@ -30,7 +30,7 @@
"cross-spawn": "7.0.3",
"prettier": "2.0.5",
"ts-node": "8.0.0",
- "typescript": "3.9.7"
+ "typescript": "4.0"
},
"prettier": {
"singleQuote": true, | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-typescript-styled-components/package.json | @@ -18,7 +18,7 @@
"@types/react-dom": "16.8.4",
"@types/styled-components": "5.0.1",
"babel-plugin-styled-components": "^1.10.0",
- "typescript": "3.5.2"
+ "typescript": "4.0"
},
"license": "ISC"
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-typescript-types/package.json | @@ -17,7 +17,7 @@
"@types/node": "^12.12.21",
"@types/react": "^16.9.16",
"@types/react-dom": "^16.9.4",
- "typescript": "3.7.3"
+ "typescript": "4.0"
},
"license": "MIT"
} | true |
Other | vercel | next.js | 694ccc7ca08c4abc1993c66ba0a1478ffcad3826.json | Upgrade typescript to 4.0 (#16673) | examples/with-typescript/package.json | @@ -16,7 +16,7 @@
"@types/node": "^12.12.21",
"@types/react": "^16.9.16",
"@types/react-dom": "^16.9.4",
- "typescript": "3.9.7"
+ "typescript": "4.0"
},
"license": "ISC"
} | true |
Other | vercel | next.js | 8217597848ae06596c64c553a5f7bf805fca2b06.json | Add activeClassName to Link examples (#16658)
Allows people to more easily find how to style active links if they are wanting to | docs/api-reference/next/link.md | @@ -8,6 +8,7 @@ description: Enable client-side transitions between routes with the built-in Lin
<summary><b>Examples</b></summary>
<ul>
<li><a href="https://github.com/vercel/next.js/tree/canary/examples/hello-world">Hello World</a></li>
+ <li><a href="https://github.com/vercel/next.js/tree/canary/exampl... | false |
Other | vercel | next.js | 20a4928b16335ea3b6ec06df7c3cdefc0cd8df7a.json | remove unneeded error (#16636)
This is not needed anymore since absolute urls are supported.
Also added an extra test for `mailto:` urls | packages/next/next-server/lib/router/router.ts | @@ -115,23 +115,6 @@ function prepareUrlAs(router: NextRouter, url: Url, as: Url) {
}
}
-function tryParseRelativeUrl(
- url: string
-): null | ReturnType<typeof parseRelativeUrl> {
- try {
- return parseRelativeUrl(url)
- } catch (err) {
- if (process.env.NODE_ENV !== 'production') {
- setTimeout((... | true |
Other | vercel | next.js | 20a4928b16335ea3b6ec06df7c3cdefc0cd8df7a.json | remove unneeded error (#16636)
This is not needed anymore since absolute urls are supported.
Also added an extra test for `mailto:` urls | test/integration/invalid-href/test/index.test.js | @@ -135,6 +135,12 @@ describe('Invalid hrefs', () => {
const $ = cheerio.load(await res.text())
expect($('#click-me').attr('href')).toBe('https://')
})
+
+ it('renders a link with mailto: href', async () => {
+ const res = await fetchViaHTTP(appPort, '/first')
+ const $ = cheerio.load(aw... | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/pages/api/disable.js | @@ -0,0 +1,4 @@
+export default (req, res) => {
+ res.clearPreviewData({})
+ res.end('disabled')
+} | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/pages/api/enable.js | @@ -0,0 +1,4 @@
+export default (req, res) => {
+ res.setPreviewData({})
+ res.end('enabled')
+} | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/pages/fallback/[post].js | @@ -0,0 +1,20 @@
+export default function Post(props) {
+ return <p id="props">{JSON.stringify(props)}</p>
+}
+
+export const getStaticProps = ({ preview, previewData, params }) => {
+ return {
+ props: {
+ params,
+ preview: !!preview,
+ previewData: previewData || null,
+ },
+ }
+}
+
+export c... | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/pages/index.js | @@ -0,0 +1,12 @@
+export const getStaticProps = ({ preview, previewData }) => {
+ return {
+ props: {
+ preview: !!preview,
+ previewData: previewData || null,
+ },
+ }
+}
+
+export default function Index(props) {
+ return <p id="props">{JSON.stringify(props)}</p>
+} | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/pages/no-fallback/[post].js | @@ -0,0 +1,20 @@
+export default function Post(props) {
+ return <p id="props">{JSON.stringify(props)}</p>
+}
+
+export const getStaticProps = ({ preview, previewData, params }) => {
+ return {
+ props: {
+ params,
+ preview: !!preview,
+ previewData: previewData || null,
+ },
+ }
+}
+
+export c... | true |
Other | vercel | next.js | 990c1792d2af53e1c178ca675a3b40e11c6b159d.json | Add tests for preview mode caching (#16579)
This adds tests to ensure preview mode pages aren't cached and made publicly available or written to the disk.
Closes: https://github.com/vercel/next.js/issues/16020 | test/integration/preview-fallback/test/index.test.js | @@ -0,0 +1,327 @@
+/* eslint-env jest */
+
+import cheerio from 'cheerio'
+import cookie from 'cookie'
+import fs from 'fs-extra'
+import { join } from 'path'
+import webdriver from 'next-webdriver'
+import {
+ fetchViaHTTP,
+ findPort,
+ killApp,
+ launchApp,
+ nextBuild,
+ nextStart,
+ File,
+ renderViaHTTP,
... | true |
Other | vercel | next.js | 34f737c47bd1764b81be4ebda5d93a7ee5ee1070.json | Increase font test timeout for Windows (#16527) | test/integration/font-optimization/test/index.test.js | @@ -11,7 +11,7 @@ import {
} from 'next-test-utils'
import fs from 'fs-extra'
-jest.setTimeout(1000 * 30)
+jest.setTimeout(1000 * 60 * 2)
const appDir = join(__dirname, '../')
const nextConfig = join(appDir, 'next.config.js') | false |
Other | vercel | next.js | 35a90d0e0c0bf303fac3d07976d7b6023fd60676.json | examples/with-styled-components: Fix missing peerDependency (#16532)
styled-components requires 'react-is' as a peerDependency
###### Reference
- https://github.com/styled-components/styled-components/blob/b19d17f/packages/styled-components/package.json#L78 | examples/with-styled-components/package.json | @@ -10,6 +10,7 @@
"next": "latest",
"react": "^16.8.0",
"react-dom": "^16.8.0",
+ "react-is": "^16.8.0",
"styled-components": "^5.0.0"
},
"devDependencies": { | false |
Other | vercel | next.js | ed0820f763e74d0071625030aed70b3b21184aef.json | Enable webpack 5 caching by default (#16531)
When the webpack 5 beta is used disk caching will be automatically enabled to improve incremental build performance. | packages/next/build/webpack-config.ts | @@ -238,7 +238,7 @@ export default async function getBaseWebpackConfig(
pagesDir,
cwd: dir,
// Webpack 5 has a built-in loader cache
- cache: !config.experimental.unstable_webpack5cache,
+ cache: !isWebpack5,
babelPresetPlugins,
hasModern: !!config.experimental... | true |
Other | vercel | next.js | ed0820f763e74d0071625030aed70b3b21184aef.json | Enable webpack 5 caching by default (#16531)
When the webpack 5 beta is used disk caching will be automatically enabled to improve incremental build performance. | packages/next/next-server/server/config.ts | @@ -54,7 +54,6 @@ const defaultConfig: { [key: string]: any } = {
optimizeFonts: false,
optimizeImages: false,
scrollRestoration: false,
- unstable_webpack5cache: false,
},
future: {
excludeDefaultMomentLocales: false, | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | errors/missing-document-component.md | @@ -0,0 +1,13 @@
+# Missing Document Components
+
+#### Why This Error Occurred
+
+In your custom `pages/_document` an expected sub-component was not rendered.
+
+#### Possible Ways to Fix It
+
+Make sure to import and render all of the expected `Document` components.
+
+### Useful Links
+
+- [Custom Document Docs](htt... | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | packages/next/next-server/lib/utils.ts | @@ -166,6 +166,12 @@ export type DocumentInitialProps = RenderPageResult & {
export type DocumentProps = DocumentInitialProps & {
__NEXT_DATA__: NEXT_DATA
dangerousAsPath: string
+ docComponentsRendered: {
+ Html?: boolean
+ Main?: boolean
+ Head?: boolean
+ NextScript?: boolean
+ }
buildManifes... | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | packages/next/next-server/server/render.tsx | @@ -41,6 +41,7 @@ import {
loadGetInitialProps,
NextComponentType,
RenderPage,
+ DocumentProps,
} from '../lib/utils'
import { tryGetPreviewData, __ApiPreviewProps } from './api-utils'
import { denormalizePagePath } from './denormalize-page-path'
@@ -158,6 +159,7 @@ function renderDocument(
Document: Do... | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | packages/next/pages/_document.tsx | @@ -123,7 +123,12 @@ export function Html(
HTMLHtmlElement
>
) {
- const { inAmpMode } = useContext(DocumentComponentContext)
+ const { inAmpMode, docComponentsRendered } = useContext(
+ DocumentComponentContext
+ )
+
+ docComponentsRendered.Html = true
+
return (
<html
{...props}
@@ -288... | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | test/integration/missing-document-component-error/pages/index.js | @@ -0,0 +1,3 @@
+export default function Index() {
+ return <p>Index page</p>
+} | true |
Other | vercel | next.js | a7550bf1d7b2a2c4075b4ba958a03e21612e93ad.json | Add error when document component isn't rendered (#16459)
If a custom `_document` is added but not all of the expected document components are rendered it can cause unintended errors as noticed in https://github.com/vercel/next.js/issues/10219 so this adds detecting when one of the expected document components isn't r... | test/integration/missing-document-component-error/test/index.test.js | @@ -0,0 +1,159 @@
+/* eslint-env jest */
+
+import fs from 'fs-extra'
+import { join } from 'path'
+import {
+ findPort,
+ killApp,
+ launchApp,
+ check,
+ renderViaHTTP,
+} from 'next-test-utils'
+
+jest.setTimeout(1000 * 60 * 2)
+
+const appDir = join(__dirname, '..')
+const docPath = join(appDir, 'pages/_docume... | true |
Other | vercel | next.js | f2ba97d866863b46b3dcb68c9652a78d9fa0c4a9.json | Add webpack 5 cache invalidation (#16494)
Handles:
- Next.js version
- next.config.js `env` key
- `NEXT_PUBLIC_` prefixed environment variables
- next.config.js keys that affect performance
Ideally we don't invalidate the whole cache when `NEXT_PUBLIC_` / `env` key variables change, but this is just to initially mak... | packages/next/build/webpack-config.ts | @@ -1121,10 +1121,68 @@ export default async function getBaseWebpackConfig(
// Enable webpack 5 caching
if (config.experimental.unstable_webpack5cache) {
- webpackConfig.cache = {
+ const nextPublicVariables = Object.keys(process.env).reduce(
+ (prev: string, key: string) => {
+ if... | true |
Other | vercel | next.js | f2ba97d866863b46b3dcb68c9652a78d9fa0c4a9.json | Add webpack 5 cache invalidation (#16494)
Handles:
- Next.js version
- next.config.js `env` key
- `NEXT_PUBLIC_` prefixed environment variables
- next.config.js keys that affect performance
Ideally we don't invalidate the whole cache when `NEXT_PUBLIC_` / `env` key variables change, but this is just to initially mak... | packages/next/next-server/server/config.ts | @@ -277,7 +277,11 @@ export default function loadConfig(
)
}
- return assignDefaults({ configOrigin: CONFIG_FILE, ...userConfig })
+ return assignDefaults({
+ configOrigin: CONFIG_FILE,
+ configFile: path,
+ ...userConfig,
+ })
} else {
const configBaseName = basename(CONFI... | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/.gitignore | @@ -1,34 +0,0 @@
-# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
-
-# dependencies
-/node_modules
-/.pnp
-.pnp.js
-
-# testing
-/coverage
-
-# next.js
-/.next/
-/out/
-
-# production
-/build
-
-# misc
-.DS_Store
-*.pem
-
-# debug
-npm-debug.log*
-yarn-debug.log*
-yarn-error.log*
-... | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/README.md | @@ -1,14 +0,0 @@
-# z-experimental-refresh
-
-This is an **experimental** demo of React Fast Refresh.
-Please do not use these features in your application or project (yet).
-
-## Usage
-
-Run the following command to get started:
-
-```bash
-yarn dev
-# or
-npm run dev
-``` | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/components/ClickCount.js | @@ -1,15 +0,0 @@
-import { useCallback, useState } from 'react'
-import styles from './ClickCount.module.css'
-
-export default function ClickCount() {
- const [count, setCount] = useState(0)
- const increment = useCallback(() => {
- setCount((v) => v + 1)
- }, [setCount])
-
- return (
- <button className={st... | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/components/ClickCount.module.css | @@ -1,32 +0,0 @@
-button.btn {
- margin: 0;
- border: 1px solid #d1d1d1;
- border-radius: 5px;
- padding: 0.5em;
- vertical-align: middle;
- white-space: normal;
- background: none;
- line-height: 1;
- font-size: 1rem;
- font-family: inherit;
- transition: all 0.2s ease;
-}
-
-button.btn {
- padding: 0.65em... | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/global.css | @@ -1,41 +0,0 @@
-body {
- font-family: 'SF Pro Text', 'SF Pro Icons', 'Helvetica Neue', 'Helvetica',
- 'Arial', sans-serif;
- padding: 20px 20px 60px;
- max-width: 680px;
- margin: 0 auto;
- font-size: 16px;
- line-height: 1.65;
- word-break: break-word;
- font-kerning: auto;
- font-variant: normal;
- -we... | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/package.json | @@ -1,15 +0,0 @@
-{
- "name": "z-experimental-refresh",
- "version": "1.0.0",
- "scripts": {
- "dev": "next",
- "build": "next build",
- "start": "next start"
- },
- "dependencies": {
- "next": "canary",
- "react": "^16.9.0",
- "react-dom": "^16.9.0"
- },
- "license": "MIT"
-} | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/pages/_app.js | @@ -1,5 +0,0 @@
-import '../global.css'
-
-export default function MyApp({ Component, pageProps }) {
- return <Component {...pageProps} />
-} | true |
Other | vercel | next.js | ec281df70b4d314d41b7d3bc7d0a8ddd42444d7a.json | Remove experimental example (#16497)
@Timer This example seems to not be needed anymore | examples/z-experimental-refresh/pages/index.js | @@ -1,60 +0,0 @@
-import { useCallback, useEffect, useState } from 'react'
-import ClickCount from '../components/ClickCount'
-import styles from '../components/ClickCount.module.css'
-
-function a() {
- console.log(
- // hello
- document.body()
- )
-}
-
-function foo() {
- a()
-}
-
-function Home() {
- const... | true |
Other | vercel | next.js | 4d0d09ba9da07fcfe4825ca4e3118dabfae9c45f.json | Add version note to path aliases docs (#16479)
* Add version note to path aliases docs
* Update docs/advanced-features/module-path-aliases.md
Co-authored-by: Luis Alvarez D <luis@vercel.com> | docs/advanced-features/module-path-aliases.md | @@ -4,7 +4,7 @@ description: Configure module path aliases that allow you to remap certain impor
# Absolute Imports and Module path aliases
-Next.js automatically supports the `tsconfig.json` and `jsconfig.json` `"paths"` and `"baseUrl"` options.
+Next.js automatically supports the `tsconfig.json` and `jsconfig.js... | false |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/build-manifest-plugin.ts | @@ -1,6 +1,6 @@
import devalue from 'next/dist/compiled/devalue'
import webpack, { Compiler, compilation as CompilationType } from 'webpack'
-import { RawSource } from 'webpack-sources'
+import sources from 'webpack-sources'
import {
BUILD_MANIFEST,
CLIENT_STATIC_FILES_PATH,
@@ -15,6 +15,9 @@ import { ampFirst... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/css-minimizer-plugin.ts | @@ -1,6 +1,9 @@
import { process as minify } from 'cssnano-simple'
import webpack from 'webpack'
-import { RawSource, SourceMapSource } from 'webpack-sources'
+import sources from 'webpack-sources'
+
+// @ts-ignore: TODO: remove ignore when webpack 5 is stable
+const { RawSource, SourceMapSource } = webpack.sources |... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/font-stylesheet-gathering-plugin.ts | @@ -1,6 +1,6 @@
import webpack, { compilation as CompilationType, Compiler } from 'webpack'
import { namedTypes } from 'ast-types'
-import { RawSource } from 'webpack-sources'
+import sources from 'webpack-sources'
import {
getFontDefinitionFromNetwork,
FontManifest,
@@ -11,6 +11,9 @@ import postcss from 'post... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/mini-css-extract-plugin/src/index.js | @@ -6,7 +6,8 @@ import sources from 'webpack-sources'
import CssDependency from './CssDependency'
import CssModule from './CssModule'
-const { ConcatSource, SourceMapSource, OriginalSource } = sources
+const { ConcatSource, SourceMapSource, OriginalSource } =
+ webpack.sources || sources
const {
Template,
u... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/nextjs-ssr-module-cache.ts | @@ -1,9 +1,12 @@
import webpack from 'webpack'
-import { RawSource } from 'webpack-sources'
+import sources from 'webpack-sources'
import { join, relative, dirname } from 'path'
import getRouteFromEntrypoint from '../../../next-server/server/get-route-from-entrypoint'
const SSR_MODULE_CACHE_FILENAME = 'ssr-module-c... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/pages-manifest-plugin.ts | @@ -1,10 +1,13 @@
import webpack, { Compiler, Plugin } from 'webpack'
-import { RawSource } from 'webpack-sources'
+import sources from 'webpack-sources'
import { PAGES_MANIFEST } from '../../../next-server/lib/constants'
import getRouteFromEntrypoint from '../../../next-server/server/get-route-from-entrypoint'
e... | true |
Other | vercel | next.js | d0754993fc46481766c3632ca6f19b62bd8b670b.json | Add webpack 5 caching for css optimizer (#16467) | packages/next/build/webpack/plugins/react-loadable-plugin.ts | @@ -28,6 +28,9 @@ import webpack, {
} from 'webpack'
import sources from 'webpack-sources'
+// @ts-ignore: TODO: remove ignore when webpack 5 is stable
+const { RawSource } = webpack.sources || sources
+
const isWebpack5 = parseInt(webpack.version!) === 5
function getModulesIterable(compilation: any, chunk: any... | true |
Other | vercel | next.js | 167a91b73e048211a855b38f50e7f551cdddd4cb.json | Remove un-helpful error in with-sentry example (#36902)
The error reported here is unclear and un-helpful so we shouldn't be recommending to report this by default.
x-ref: [slack thread](https://vercel.slack.com/archives/CGU8HUTUH/p1652466540356879)
## Documentation / Examples
- [x] Make sure the linting passes b... | examples/with-sentry/pages/_error.js | @@ -14,7 +14,7 @@ const MyError = ({ statusCode, hasGetInitialPropsRun, err }) => {
return <NextErrorComponent statusCode={statusCode} />
}
-MyError.getInitialProps = async ({ res, err, asPath }) => {
+MyError.getInitialProps = async ({ res, err }) => {
const errorInitialProps = await NextErrorComponent.getIni... | false |
Other | vercel | next.js | d67baa0d1fef8a411679c9b9bdea39cb476ce2d5.json | Fix return type of middleware `req.cookies.get()` (#36872)
Follow up to #36478
Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com> | packages/next/server/web/spec-extension/cookies.ts | @@ -35,7 +35,7 @@ const deserializeCookie = (input: Request | Response): string[] => {
const serializeCookie = (input: string[]) => input.join(', ')
-export class Cookies extends Map<string, any> {
+export class Cookies extends Map<string, string> {
constructor(input?: string | null) {
const parsedInput = ... | true |
Other | vercel | next.js | d67baa0d1fef8a411679c9b9bdea39cb476ce2d5.json | Fix return type of middleware `req.cookies.get()` (#36872)
Follow up to #36478
Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com> | test/production/middleware-typescript/app/pages/rewrites/_middleware.ts | @@ -10,6 +10,9 @@ export const middleware: NextMiddleware = async function (request) {
const response = NextResponse.rewrite(`/rewrites/${bucket}`)
response.cookies.set('bucket', bucket, { maxAge: 10 })
return response
+ } else {
+ // check that `bucket` is type "string", not "any"
+ b... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | packages/next/build/webpack-config.ts | @@ -1408,6 +1408,9 @@ export default async function getBaseWebpackConfig(
isEdgeServer ? 'edge' : 'nodejs'
),
}),
+ 'process.env.__NEXT_MANUAL_CLIENT_BASE_PATH': JSON.stringify(
+ config.experimental.manualClientBasePath
+ ),
'process.env.__NEXT_NEW_LINK_... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | packages/next/client/page-loader.ts | @@ -156,7 +156,8 @@ export default class PageLoader {
'.json'
)
return addBasePath(
- `/_next/data/${this.buildId}${dataRoute}${ssg ? '' : search}`
+ `/_next/data/${this.buildId}${dataRoute}${ssg ? '' : search}`,
+ true
)
}
| true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | packages/next/server/config-shared.ts | @@ -79,6 +79,7 @@ export interface NextJsWebpackConfig {
}
export interface ExperimentalConfig {
+ manualClientBasePath?: boolean
newNextLinkBehavior?: boolean
disablePostcssPresetEnv?: boolean
swcMinify?: boolean | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | packages/next/shared/lib/router/router.ts | @@ -205,12 +205,23 @@ export function hasBasePath(path: string): boolean {
return hasPathPrefix(path, basePath)
}
-export function addBasePath(path: string): string {
+export function addBasePath(path: string, required?: boolean): string {
+ if (process.env.__NEXT_MANUAL_CLIENT_BASE_PATH) {
+ if (!required) {... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | test/e2e/manual-client-base-path/app/next.config.js | @@ -0,0 +1,6 @@
+module.exports = {
+ basePath: '/docs-proxy',
+ experimental: {
+ manualClientBasePath: true,
+ },
+} | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | test/e2e/manual-client-base-path/app/pages/another.js | @@ -0,0 +1,50 @@
+import Link from 'next/link'
+import { useRouter } from 'next/router'
+import { useEffect, useState } from 'react'
+
+export default function Page(props) {
+ const router = useRouter()
+ const [mounted, setMounted] = useState(false)
+
+ useEffect(() => {
+ setMounted(true)
+ }, [])
+
+ return ... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | test/e2e/manual-client-base-path/app/pages/dynamic/[slug].js | @@ -0,0 +1,58 @@
+import Link from 'next/link'
+import { useRouter } from 'next/router'
+import { useEffect, useState } from 'react'
+
+export default function Page(props) {
+ const router = useRouter()
+ const [mounted, setMounted] = useState(false)
+
+ useEffect(() => {
+ setMounted(true)
+ }, [])
+
+ return ... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | test/e2e/manual-client-base-path/app/pages/index.js | @@ -0,0 +1,41 @@
+import Link from 'next/link'
+import { useRouter } from 'next/router'
+import { useEffect, useState } from 'react'
+
+export default function Page(props) {
+ const router = useRouter()
+ const [mounted, setMounted] = useState(false)
+
+ useEffect(() => {
+ setMounted(true)
+ }, [])
+
+ return ... | true |
Other | vercel | next.js | 03d00e284f7979a3384608666b8305603fd5f12a.json | Add experimental config for basePath testing (#36843)
This adds an experimental config for testing `basePath` handling on the client.
x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559)
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Err... | test/e2e/manual-client-base-path/index.test.ts | @@ -0,0 +1,193 @@
+import { createNext, FileRef } from 'e2e-utils'
+import { NextInstance } from 'test/lib/next-modes/base'
+import httpProxy from 'http-proxy'
+import { join } from 'path'
+import http from 'http'
+import webdriver from 'next-webdriver'
+import assert from 'assert'
+import { check, waitFor } from 'next... | true |
Other | vercel | next.js | b596ce9d6a23b3b8e394f01c39625c54356661ff.json | chore: upgrade dependencies in Jest examples (#36858)
Ref: https://github.com/vercel/next.js/issues/36842, https://github.com/vercel/next.js/pull/36632, https://github.com/vercel/next.js/pull/36787
Upgrading to Jest 28, and aligning Babel example with `with-jest`
## Bug
- [ ] Related issues linked using `fixes #nu... | examples/with-jest-babel/README.md | @@ -11,11 +11,11 @@ Quickly get started using [Create Next App](https://github.com/vercel/next.js/tr
In your terminal, run the following command:
```bash
-npx create-next-app --example with-jest with-jest-app
+npx create-next-app --example with-jest-babel with-jest-babel-app
# or
-yarn create next-app --example wi... | true |
Other | vercel | next.js | b596ce9d6a23b3b8e394f01c39625c54356661ff.json | chore: upgrade dependencies in Jest examples (#36858)
Ref: https://github.com/vercel/next.js/issues/36842, https://github.com/vercel/next.js/pull/36632, https://github.com/vercel/next.js/pull/36787
Upgrading to Jest 28, and aligning Babel example with `with-jest`
## Bug
- [ ] Related issues linked using `fixes #nu... | examples/with-jest-babel/package.json | @@ -2,28 +2,25 @@
"private": true,
"scripts": {
"dev": "next dev",
- "lint": "next lint",
"build": "next build",
"start": "next start",
"test": "jest --watch",
"test:ci": "jest --ci"
},
"dependencies": {
"next": "latest",
- "react": "^17.0.2",
- "react-dom": "^17.0.2"
... | true |
Other | vercel | next.js | b596ce9d6a23b3b8e394f01c39625c54356661ff.json | chore: upgrade dependencies in Jest examples (#36858)
Ref: https://github.com/vercel/next.js/issues/36842, https://github.com/vercel/next.js/pull/36632, https://github.com/vercel/next.js/pull/36787
Upgrading to Jest 28, and aligning Babel example with `with-jest`
## Bug
- [ ] Related issues linked using `fixes #nu... | examples/with-jest/package.json | @@ -9,15 +9,16 @@
},
"dependencies": {
"next": "latest",
- "react": "^17.0.2",
- "react-dom": "^17.0.2"
+ "react": "^18.1.0",
+ "react-dom": "^18.1.0"
},
"devDependencies": {
- "@testing-library/jest-dom": "5.16.1",
- "@testing-library/react": "12.1.2",
- "@testing-library/user-eve... | true |
Other | vercel | next.js | 093288c9d79a64411355c9c5e5db76d353cd8890.json | fix(#30300): force export 404.html (#36827)
## Bug
- [x] Related issues linked using `fixes #number`
- [x] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`
The PR fixes #30300.
The previous integration test case only checks if `/out/404.html` exists. However, the test passes ... | packages/next/export/worker.ts | @@ -221,8 +221,13 @@ export default async function exportPage({
// extension of `.slug]`
const pageExt = isDynamic ? '' : extname(page)
const pathExt = isDynamic ? '' : extname(path)
+
+ // force output 404.html for backwards compat
+ if (path === '/404.html') {
+ htmlFilename = pa... | true |
Other | vercel | next.js | 093288c9d79a64411355c9c5e5db76d353cd8890.json | fix(#30300): force export 404.html (#36827)
## Bug
- [x] Related issues linked using `fixes #number`
- [x] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`
The PR fixes #30300.
The previous integration test case only checks if `/out/404.html` exists. However, the test passes ... | test/integration/export/test/index.test.js | @@ -20,7 +20,7 @@ import { promises } from 'fs'
import dynamic from './dynamic'
import apiRoutes from './api-routes'
-const { access, mkdir, writeFile } = promises
+const { access, mkdir, writeFile, stat } = promises
const appDir = join(__dirname, '../')
const outdir = join(appDir, 'out')
const outNoTrailSlash =... | true |
Other | vercel | next.js | d76bbde311da00cd750bf48d49887610960cafb9.json | fix(#36534): enable interopClientDefaultExport for next/jest (#36824) | packages/next/jest.js | @@ -1,4 +1 @@
-function interopDefault(mod) {
- return mod.default || mod
-}
-module.exports = interopDefault(require('./dist/build/jest/jest'))
+module.exports = require('./dist/build/jest/jest') | true |
Other | vercel | next.js | d76bbde311da00cd750bf48d49887610960cafb9.json | fix(#36534): enable interopClientDefaultExport for next/jest (#36824) | packages/next/taskfile.js | @@ -1763,6 +1763,7 @@ export async function compile(task, opts) {
'bin',
'server',
'nextbuild',
+ 'nextbuildjest',
'nextbuildstatic',
'pages',
'lib',
@@ -1816,13 +1817,23 @@ export async function server(task, opts) {
export async function nextbuild(task, opts) {
await ... | true |
Other | vercel | next.js | 8f9296c00d849ed4bf4bdaeb8cc9dc0f28ad808e.json | Add final newline to package-lock.json (#36813)
This aligns the output with what npm outputs. Without this change,
Next.js causes unwanted changes in package-lock.json.
## Bug
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md... | packages/next/lib/patch-incorrect-lockfile.ts | @@ -87,7 +87,7 @@ export async function patchIncorrectLockfile(dir: string) {
await promises.writeFile(
lockfilePath,
- JSON.stringify(lockfileParsed, null, 2)
+ `${JSON.stringify(lockfileParsed, null, 2)}\n`
)
Log.warn(
'Lockfile was successfully patched, please r... | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.