Skip to content

Commit

Permalink
Merge branch 'canary' into create-next-app/support-pnpm
Browse files Browse the repository at this point in the history
  • Loading branch information
kawaemon committed Feb 2, 2021
2 parents 342f603 + b6c3d9b commit ae02133
Show file tree
Hide file tree
Showing 24 changed files with 34 additions and 27 deletions.
3 changes: 2 additions & 1 deletion .github/actions/next-stats-action/package.json
Expand Up @@ -13,6 +13,7 @@
"node-fetch": "^2.6.0",
"prettier": "^1.18.2",
"pretty-bytes": "^5.3.0",
"pretty-ms": "^5.0.0"
"pretty-ms": "^5.0.0",
"semver": "7.3.4"
}
}
1 change: 1 addition & 0 deletions .github/actions/next-stats-action/src/index.js
Expand Up @@ -74,6 +74,7 @@ if (!allowedActions.has(actionInfo.actionName) && !actionInfo.isRelease) {
logger('Release detected, resetting mainRepo to last stable tag')
const lastStableTag = await getLastStable(mainRepoDir, actionInfo.prRef)
if (!lastStableTag) throw new Error('failed to get last stable tag')
console.log('using latestStable', lastStableTag)
await checkoutRef(lastStableTag, mainRepoDir)

/* eslint-disable-next-line */
Expand Down
6 changes: 4 additions & 2 deletions .github/actions/next-stats-action/src/prepare/repo-setup.js
Expand Up @@ -3,6 +3,7 @@ const fs = require('fs-extra')
const exec = require('../util/exec')
const { remove } = require('fs-extra')
const logger = require('../util/logger')
const semver = require('semver')

module.exports = (actionInfo) => {
return {
Expand All @@ -22,8 +23,9 @@ module.exports = (actionInfo) => {
const curTag = tags[i]
// stable doesn't include `-canary` or `-beta`
if (!curTag.includes('-') && !ref.includes(curTag)) {
lastStableTag = curTag
break
if (!lastStableTag || semver.gt(curTag, lastStableTag)) {
lastStableTag = curTag
}
}
}
return lastStableTag
Expand Down
2 changes: 1 addition & 1 deletion docs/api-routes/introduction.md
Expand Up @@ -23,7 +23,7 @@ For example, the following API route `pages/api/user.js` returns a `json` respon

```js
export default function handler(req, res) {
res.status(200).json({ name: 'John Doe' }))
res.status(200).json({ name: 'John Doe' })
}
```

Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Expand Up @@ -17,5 +17,5 @@
"registry": "https://registry.npmjs.org/"
}
},
"version": "10.0.6"
"version": "10.0.7-canary.0"
}
2 changes: 1 addition & 1 deletion packages/create-next-app/package.json
@@ -1,6 +1,6 @@
{
"name": "create-next-app",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"keywords": [
"react",
"next",
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint-plugin-next/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/eslint-plugin-next",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "ESLint plugin for NextJS.",
"main": "lib/index.js",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion packages/next-bundle-analyzer/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/bundle-analyzer",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"main": "index.js",
"license": "MIT",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/next-codemod/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/codemod",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"license": "MIT",
"dependencies": {
"chalk": "4.1.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/next-env/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/env",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"keywords": [
"react",
"next",
Expand Down
2 changes: 1 addition & 1 deletion packages/next-mdx/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/mdx",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"main": "index.js",
"license": "MIT",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/next-plugin-google-analytics/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/plugin-google-analytics",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"repository": {
"url": "vercel/next.js",
"directory": "packages/next-plugin-google-analytics"
Expand Down
2 changes: 1 addition & 1 deletion packages/next-plugin-sentry/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/plugin-sentry",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"repository": {
"url": "vercel/next.js",
"directory": "packages/next-plugin-sentry"
Expand Down
2 changes: 1 addition & 1 deletion packages/next-plugin-storybook/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/plugin-storybook",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"repository": {
"url": "vercel/next.js",
"directory": "packages/next-plugin-storybook"
Expand Down
2 changes: 1 addition & 1 deletion packages/next-polyfill-module/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/polyfill-module",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "A standard library polyfill for ES Modules supporting browsers (Edge 16+, Firefox 60+, Chrome 61+, Safari 10.1+)",
"main": "dist/polyfill-module.js",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion packages/next-polyfill-nomodule/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/polyfill-nomodule",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "A polyfill for non-dead, nomodule browsers.",
"main": "dist/polyfill-nomodule.js",
"license": "MIT",
Expand Down
12 changes: 6 additions & 6 deletions packages/next/package.json
@@ -1,6 +1,6 @@
{
"name": "next",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "The React Framework",
"main": "./dist/server/next.js",
"license": "MIT",
Expand Down Expand Up @@ -63,10 +63,10 @@
"@ampproject/toolbox-optimizer": "2.7.1-alpha.0",
"@babel/runtime": "7.12.5",
"@hapi/accept": "5.0.1",
"@next/env": "10.0.6",
"@next/polyfill-module": "10.0.6",
"@next/react-dev-overlay": "10.0.6",
"@next/react-refresh-utils": "10.0.6",
"@next/env": "10.0.7-canary.0",
"@next/polyfill-module": "10.0.7-canary.0",
"@next/react-dev-overlay": "10.0.7-canary.0",
"@next/react-refresh-utils": "10.0.7-canary.0",
"@opentelemetry/api": "0.14.0",
"ast-types": "0.13.2",
"browserslist": "4.16.1",
Expand Down Expand Up @@ -135,7 +135,7 @@
"@babel/preset-react": "7.12.10",
"@babel/preset-typescript": "7.12.7",
"@babel/types": "7.12.12",
"@next/polyfill-nomodule": "10.0.6",
"@next/polyfill-nomodule": "10.0.7-canary.0",
"@taskr/clear": "1.1.0",
"@taskr/esnext": "1.1.0",
"@taskr/watch": "1.1.0",
Expand Down
3 changes: 3 additions & 0 deletions packages/next/types/index.d.ts
Expand Up @@ -23,6 +23,9 @@ import {
// @ts-ignore This path is generated at build time and conflicts otherwise
import next from '../dist/server/next'

declare module 'next/dist/compiled/loader-utils'
declare module 'next/dist/compiled/webpack/webpack'

// Extend the React types with missing properties
declare module 'react' {
// <html amp=""> support
Expand Down
2 changes: 1 addition & 1 deletion packages/react-dev-overlay/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/react-dev-overlay",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "A development-only overlay for developing React applications.",
"repository": {
"url": "vercel/next.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/react-refresh-utils/package.json
@@ -1,6 +1,6 @@
{
"name": "@next/react-refresh-utils",
"version": "10.0.6",
"version": "10.0.7-canary.0",
"description": "An experimental package providing utilities for React Refresh.",
"repository": {
"url": "vercel/next.js",
Expand Down
2 changes: 1 addition & 1 deletion test/integration/build-output/test/index.test.js
Expand Up @@ -104,7 +104,7 @@ describe('Build Output', () => {
expect(parseFloat(err404FirstLoad)).toBeCloseTo(67, 1)
expect(err404FirstLoad.endsWith('kB')).toBe(true)

expect(parseFloat(sharedByAll)).toBeCloseTo(63.5, 1)
expect(parseFloat(sharedByAll)).toBeCloseTo(63.6, 1)
expect(sharedByAll.endsWith('kB')).toBe(true)

if (_appSize.endsWith('kB')) {
Expand Down
1 change: 1 addition & 0 deletions test/integration/script-loader/pages/_document.js
Expand Up @@ -23,6 +23,7 @@ export default class MyDocument extends Document {
<body>
<Main />
<NextScript />
<div id="text"></div>
</body>
</html>
)
Expand Down
2 changes: 1 addition & 1 deletion test/integration/script-loader/pages/page3.js
Expand Up @@ -7,7 +7,7 @@ const Page = () => {
{`(window.onload = function () {
const newDiv = document.createElement('div')
newDiv.id = 'onload-div'
document.querySelector('.container').appendChild(newDiv)
document.querySelector('body').appendChild(newDiv)
})`}
</Script>
<Script
Expand Down
1 change: 0 additions & 1 deletion test/integration/script-loader/pages/page4.js
Expand Up @@ -30,7 +30,6 @@ const Page = () => {
document.getElementById('text').textContent += _.repeat('c', 3)
}}
></Script>
<div id="text"></div>
</div>
)
}
Expand Down

0 comments on commit ae02133

Please sign in to comment.