Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
c16f6006
Commit
c16f6006
authored
Mar 29, 2020
by
Guy Bedford
Committed by
Joe Haddad
Mar 30, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
path-to-regexp
parent
8c214949
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
46 additions
and
11 deletions
+46
-11
index.ts
packages/next/build/index.ts
+1
-1
check-custom-routes.ts
packages/next/lib/check-custom-routes.ts
+1
-1
path-match.ts
packages/next/next-server/server/lib/path-match.ts
+1
-1
router.ts
packages/next/next-server/server/router.ts
+1
-1
package.json
packages/next/package.json
+2
-1
taskfile.js
packages/next/taskfile.js
+7
-0
misc.d.ts
packages/next/types/misc.d.ts
+4
-0
yarn.lock
yarn.lock
+29
-6
No files found.
packages/next/build/index.ts
View file @
c16f6006
...
@@ -8,7 +8,7 @@ import fs from 'fs'
...
@@ -8,7 +8,7 @@ import fs from 'fs'
import
Worker
from
'jest-worker'
import
Worker
from
'jest-worker'
import
nanoid
from
'next/dist/compiled/nanoid/index.js'
import
nanoid
from
'next/dist/compiled/nanoid/index.js'
import
path
from
'path'
import
path
from
'path'
import
{
pathToRegexp
}
from
'path-to-regexp'
import
{
pathToRegexp
}
from
'
next/dist/compiled/
path-to-regexp'
import
{
promisify
}
from
'util'
import
{
promisify
}
from
'util'
import
formatWebpackMessages
from
'../client/dev/error-overlay/format-webpack-messages'
import
formatWebpackMessages
from
'../client/dev/error-overlay/format-webpack-messages'
import
checkCustomRoutes
,
{
import
checkCustomRoutes
,
{
...
...
packages/next/lib/check-custom-routes.ts
View file @
c16f6006
import
*
as
pathToRegexp
from
'path-to-regexp'
import
*
as
pathToRegexp
from
'
next/dist/compiled/
path-to-regexp'
import
{
import
{
PERMANENT_REDIRECT_STATUS
,
PERMANENT_REDIRECT_STATUS
,
TEMPORARY_REDIRECT_STATUS
,
TEMPORARY_REDIRECT_STATUS
,
...
...
packages/next/next-server/server/lib/path-match.ts
View file @
c16f6006
import
*
as
pathToRegexp
from
'path-to-regexp'
import
*
as
pathToRegexp
from
'
next/dist/compiled/
path-to-regexp'
export
{
pathToRegexp
}
export
{
pathToRegexp
}
...
...
packages/next/next-server/server/router.ts
View file @
c16f6006
import
{
IncomingMessage
,
ServerResponse
}
from
'http'
import
{
IncomingMessage
,
ServerResponse
}
from
'http'
import
{
parse
as
parseUrl
,
UrlWithParsedQuery
}
from
'url'
import
{
parse
as
parseUrl
,
UrlWithParsedQuery
}
from
'url'
import
{
compile
as
compilePathToRegex
}
from
'path-to-regexp'
import
{
compile
as
compilePathToRegex
}
from
'
next/dist/compiled/
path-to-regexp'
import
pathMatch
from
'./lib/path-match'
import
pathMatch
from
'./lib/path-match'
export
const
route
=
pathMatch
()
export
const
route
=
pathMatch
()
...
...
packages/next/package.json
View file @
c16f6006
...
@@ -70,7 +70,6 @@
...
@@ -70,7 +70,6 @@
"loader-utils"
:
"2.0.0"
,
"loader-utils"
:
"2.0.0"
,
"mini-css-extract-plugin"
:
"0.8.0"
,
"mini-css-extract-plugin"
:
"0.8.0"
,
"native-url"
:
"0.2.6"
,
"native-url"
:
"0.2.6"
,
"path-to-regexp"
:
"6.1.0"
,
"pnp-webpack-plugin"
:
"1.5.0"
,
"pnp-webpack-plugin"
:
"1.5.0"
,
"postcss-flexbugs-fixes"
:
"4.2.0"
,
"postcss-flexbugs-fixes"
:
"4.2.0"
,
"postcss-loader"
:
"3.0.0"
,
"postcss-loader"
:
"3.0.0"
,
...
@@ -138,6 +137,7 @@
...
@@ -138,6 +137,7 @@
"@types/mini-css-extract-plugin"
:
"0.8.0"
,
"@types/mini-css-extract-plugin"
:
"0.8.0"
,
"@types/nanoid"
:
"2.0.0"
,
"@types/nanoid"
:
"2.0.0"
,
"@types/node-fetch"
:
"2.3.4"
,
"@types/node-fetch"
:
"2.3.4"
,
"@types/path-to-regexp"
:
"1.7.0"
,
"@types/react"
:
"16.9.17"
,
"@types/react"
:
"16.9.17"
,
"@types/react-dom"
:
"16.9.4"
,
"@types/react-dom"
:
"16.9.4"
,
"@types/react-is"
:
"16.7.1"
,
"@types/react-is"
:
"16.7.1"
,
...
@@ -186,6 +186,7 @@
...
@@ -186,6 +186,7 @@
"nanoid"
:
"2.0.3"
,
"nanoid"
:
"2.0.3"
,
"node-fetch"
:
"2.6.0"
,
"node-fetch"
:
"2.6.0"
,
"ora"
:
"3.4.0"
,
"ora"
:
"3.4.0"
,
"path-to-regexp"
:
"6.1.0"
,
"raw-body"
:
"2.4.0"
,
"raw-body"
:
"2.4.0"
,
"recast"
:
"0.18.5"
,
"recast"
:
"0.18.5"
,
"resolve"
:
"1.11.0"
,
"resolve"
:
"1.11.0"
,
...
...
packages/next/taskfile.js
View file @
c16f6006
...
@@ -582,6 +582,12 @@ export async function ncc_unistore(task, opts) {
...
@@ -582,6 +582,12 @@ export async function ncc_unistore(task, opts) {
.
target
(
'dist/compiled/unistore'
)
.
target
(
'dist/compiled/unistore'
)
}
}
export
async
function
path_to_regexp
(
task
,
opts
)
{
await
task
.
source
(
opts
.
src
||
relative
(
__dirname
,
require
.
resolve
(
'path-to-regexp'
)))
.
target
(
'dist/compiled/path-to-regexp'
)
}
export
async
function
precompile
(
task
)
{
export
async
function
precompile
(
task
)
{
await
task
.
parallel
([
await
task
.
parallel
([
'browser_polyfills'
,
'browser_polyfills'
,
...
@@ -646,6 +652,7 @@ export async function precompile(task) {
...
@@ -646,6 +652,7 @@ export async function precompile(task) {
'ncc_terser'
,
'ncc_terser'
,
'ncc_text_table'
,
'ncc_text_table'
,
'ncc_unistore'
,
'ncc_unistore'
,
'path_to_regexp'
,
])
])
}
}
...
...
packages/next/types/misc.d.ts
View file @
c16f6006
...
@@ -156,6 +156,10 @@ declare module 'next/dist/compiled/ora' {
...
@@ -156,6 +156,10 @@ declare module 'next/dist/compiled/ora' {
import
m
from
'ora'
import
m
from
'ora'
export
=
m
export
=
m
}
}
declare
module
'next/dist/compiled/path-to-regexp'
{
import
m
from
'path-to-regexp'
export
=
m
}
declare
module
'next/dist/compiled/raw-body'
{
declare
module
'next/dist/compiled/raw-body'
{
import
m
from
'raw-body'
import
m
from
'raw-body'
export
=
m
export
=
m
...
...
yarn.lock
View file @
c16f6006
...
@@ -3147,10 +3147,10 @@
...
@@ -3147,10 +3147,10 @@
resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d"
resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d"
integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==
integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==
"@zeit/ncc@0.
22.0
":
"@zeit/ncc@0.
18.5
":
version "0.
22.0
"
version "0.
18.5
"
resolved "https://registry.yarnpkg.com/@zeit/ncc/-/ncc-0.
22.0.tgz#1a4132a375a2ffd1d6d632b0fdd9027154f6141a
"
resolved "https://registry.yarnpkg.com/@zeit/ncc/-/ncc-0.
18.5.tgz#5687df6c32f1a2e2486aa110b3454ccebda4fb9c
"
integrity sha512-
zaS6chwztGSLSEzsTJw9sLTYxQt57bPFBtsYlVtbqGvmDUsfW7xgXPYofzFa1kB9ur2dRop6IxCwPnWLBVCrbQ
==
integrity sha512-
F+SbvEAh8rchiRXqQbmD1UmbePY7dCOKTbvfFtbVbK2xMH/tyri5YKfNxXKK7eL9EWkkbqB3NTVQO6nokApeBA
==
"@zeit/ncc@^0.20.4":
"@zeit/ncc@^0.20.4":
version "0.20.5"
version "0.20.5"
...
@@ -4157,7 +4157,7 @@ browserify-zlib@^0.2.0:
...
@@ -4157,7 +4157,7 @@ browserify-zlib@^0.2.0:
dependencies:
dependencies:
pako "~1.0.5"
pako "~1.0.5"
browserslist@4.8.3, browserslist@^
1.3.6, browserslist@^1.5.2, browserslist@^1.7.6, browserslist@^
4.0.0, browserslist@^4.3.6, browserslist@^4.6.0, browserslist@^4.6.4, browserslist@^4.8.0, browserslist@^4.8.2, browserslist@^4.8.3:
browserslist@4.8.3, browserslist@^4.0.0, browserslist@^4.3.6, browserslist@^4.6.0, browserslist@^4.6.4, browserslist@^4.8.0, browserslist@^4.8.2, browserslist@^4.8.3:
version "4.8.3"
version "4.8.3"
resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.8.3.tgz#65802fcd77177c878e015f0e3189f2c4f627ba44"
resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.8.3.tgz#65802fcd77177c878e015f0e3189f2c4f627ba44"
integrity sha512-iU43cMMknxG1ClEZ2MDKeonKE1CCrFVkQK2AqO2YWFmvIrx4JWrvQ4w4hQez6EpVI8rHTtqh/ruHHDHSOKxvUg==
integrity sha512-iU43cMMknxG1ClEZ2MDKeonKE1CCrFVkQK2AqO2YWFmvIrx4JWrvQ4w4hQez6EpVI8rHTtqh/ruHHDHSOKxvUg==
...
@@ -4166,6 +4166,14 @@ browserslist@4.8.3, browserslist@^1.3.6, browserslist@^1.5.2, browserslist@^1.7.
...
@@ -4166,6 +4166,14 @@ browserslist@4.8.3, browserslist@^1.3.6, browserslist@^1.5.2, browserslist@^1.7.
electron-to-chromium "^1.3.322"
electron-to-chromium "^1.3.322"
node-releases "^1.1.44"
node-releases "^1.1.44"
browserslist@^1.3.6, browserslist@^1.5.2, browserslist@^1.7.6:
version "1.7.7"
resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-1.7.7.tgz#0bd76704258be829b2398bb50e4b62d1a166b0b9"
integrity sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk=
dependencies:
caniuse-db "^1.0.30000639"
electron-to-chromium "^1.2.7"
browserstack-local@1.4.0:
browserstack-local@1.4.0:
version "1.4.0"
version "1.4.0"
resolved "https://registry.yarnpkg.com/browserstack-local/-/browserstack-local-1.4.0.tgz#d979cac056f57b9af159b3bcd7fdc09b4354537c"
resolved "https://registry.yarnpkg.com/browserstack-local/-/browserstack-local-1.4.0.tgz#d979cac056f57b9af159b3bcd7fdc09b4354537c"
...
@@ -4469,11 +4477,21 @@ caniuse-db@^1.0.30000529, caniuse-db@^1.0.30000634:
...
@@ -4469,11 +4477,21 @@ caniuse-db@^1.0.30000529, caniuse-db@^1.0.30000634:
resolved "https://registry.yarnpkg.com/caniuse-db/-/caniuse-db-1.0.30001023.tgz#f856f71af16a5a44e81f1fcefc1673912a43da72"
resolved "https://registry.yarnpkg.com/caniuse-db/-/caniuse-db-1.0.30001023.tgz#f856f71af16a5a44e81f1fcefc1673912a43da72"
integrity sha512-EnlshvE6oAum+wWwKmJNVaoqJMjIc0bLUy4Dj77VVnz1o6bzSPr1Ze9iPy6g5ycg1xD6jGU6vBmo7pLEz2MbCQ==
integrity sha512-EnlshvE6oAum+wWwKmJNVaoqJMjIc0bLUy4Dj77VVnz1o6bzSPr1Ze9iPy6g5ycg1xD6jGU6vBmo7pLEz2MbCQ==
caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30001012, caniuse-lite@^1.0.30001017, caniuse-lite@^1.0.30001019, caniuse-lite@^1.0.30001020:
caniuse-db@^1.0.30000639:
version "1.0.30001038"
resolved "https://registry.yarnpkg.com/caniuse-db/-/caniuse-db-1.0.30001038.tgz#439606cdafff1e10e0a795a7ff72fe26965fe8ba"
integrity sha512-yeQ2l99M9upOgMIRfZEdes6HuPbQiRZIMBumUwdXeEQz+faSXUZtZ8xeyEdU+TlJckH09M5NtM038sjKsRa2ow==
caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30001012, caniuse-lite@^1.0.30001017, caniuse-lite@^1.0.30001019:
version "1.0.30001019"
version "1.0.30001019"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001019.tgz#857e3fccaad2b2feb3f1f6d8a8f62d747ea648e1"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001019.tgz#857e3fccaad2b2feb3f1f6d8a8f62d747ea648e1"
integrity sha512-6ljkLtF1KM5fQ+5ZN0wuyVvvebJxgJPTmScOMaFuQN2QuOzvRJnWSKfzQskQU5IOU4Gap3zasYPIinzwUjoj/g==
integrity sha512-6ljkLtF1KM5fQ+5ZN0wuyVvvebJxgJPTmScOMaFuQN2QuOzvRJnWSKfzQskQU5IOU4Gap3zasYPIinzwUjoj/g==
caniuse-lite@^1.0.30001020:
version "1.0.30001038"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001038.tgz#44da3cbca2ab6cb6aa83d1be5d324e17f141caff"
integrity sha512-zii9quPo96XfOiRD4TrfYGs+QsGZpb2cGiMAzPjtf/hpFgB6zCPZgJb7I1+EATeMw/o+lG8FyRAnI+CWStHcaQ==
capitalize@1.0.0:
capitalize@1.0.0:
version "1.0.0"
version "1.0.0"
resolved "https://registry.yarnpkg.com/capitalize/-/capitalize-1.0.0.tgz#dc802c580aee101929020d2ca14b4ca8a0ae44be"
resolved "https://registry.yarnpkg.com/capitalize/-/capitalize-1.0.0.tgz#dc802c580aee101929020d2ca14b4ca8a0ae44be"
...
@@ -6275,6 +6293,11 @@ ejs@^2.6.1:
...
@@ -6275,6 +6293,11 @@ ejs@^2.6.1:
resolved "https://registry.yarnpkg.com/ejs/-/ejs-2.7.4.tgz#48661287573dcc53e366c7a1ae52c3a120eec9ba"
resolved "https://registry.yarnpkg.com/ejs/-/ejs-2.7.4.tgz#48661287573dcc53e366c7a1ae52c3a120eec9ba"
integrity sha512-7vmuyh5+kuUyJKePhQfRQBhXV5Ce+RnaeeQArKu1EAMpL3WbgMt5WG6uQZpEVvYSSsxMXRKOewtDk9RaTKXRlA==
integrity sha512-7vmuyh5+kuUyJKePhQfRQBhXV5Ce+RnaeeQArKu1EAMpL3WbgMt5WG6uQZpEVvYSSsxMXRKOewtDk9RaTKXRlA==
electron-to-chromium@^1.2.7:
version "1.3.387"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.387.tgz#420677629c9791b5d36fc8847c8cc11c0934a6cb"
integrity sha512-jjQ6WkxrOu0rtGqY9/74Z+UEVQ7YmJU2rCX6kH4eidKP0ZK0VKB3/i1avXQ+EDwJAABKGaOAbJrcyz18P8E3aA==
electron-to-chromium@^1.3.322:
electron-to-chromium@^1.3.322:
version "1.3.327"
version "1.3.327"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.327.tgz#516f28b4271727004362b4ac814494ae64d9dde7"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.327.tgz#516f28b4271727004362b4ac814494ae64d9dde7"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment