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
a71addf2
Unverified
Commit
a71addf2
authored
Sep 28, 2021
by
JJ Kasper
Committed by
GitHub
Sep 28, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Ensure initial imports are included in traces correctly (#29437)
parent
bb8434c1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
1 deletion
+27
-1
next-trace-entrypoints-plugin.ts
...xt/build/webpack/plugins/next-trace-entrypoints-plugin.ts
+1
-1
index.test.js
test/integration/production/test/index.test.js
+26
-0
No files found.
packages/next/build/webpack/plugins/next-trace-entrypoints-plugin.ts
View file @
a71addf2
...
@@ -277,7 +277,7 @@ export class TraceEntryPointsPlugin implements webpack.Plugin {
...
@@ -277,7 +277,7 @@ export class TraceEntryPointsPlugin implements webpack.Plugin {
}
}
collectDependencies
(
entryMod
)
collectDependencies
(
entryMod
)
const
toTrace
:
string
[]
=
[
entry
,
...
depModMap
.
keys
()
]
const
toTrace
:
string
[]
=
[
entry
]
const
entryName
=
entryNameMap
.
get
(
entry
)
!
const
entryName
=
entryNameMap
.
get
(
entry
)
!
const
curExtraEntries
=
additionalEntries
.
get
(
entryName
)
const
curExtraEntries
=
additionalEntries
.
get
(
entryName
)
...
...
test/integration/production/test/index.test.js
View file @
a71addf2
...
@@ -110,6 +110,32 @@ describe('Production Usage', () => {
...
@@ -110,6 +110,32 @@ describe('Production Usage', () => {
],
],
notTests
:
[
/node_modules
\/
react
\/
cjs
\/
react
\.
development
\.
js/
],
notTests
:
[
/node_modules
\/
react
\/
cjs
\/
react
\.
development
\.
js/
],
},
},
{
page
:
'/index'
,
tests
:
[
/webpack-runtime
\.
js/
,
/chunks
\/
.*
?\.
js/
,
/node_modules
\/
react
\/
index
\.
js/
,
/node_modules
\/
react
\/
package
\.
json/
,
/node_modules
\/
react
\/
cjs
\/
react
\.
production
\.
min
\.
js/
,
/next
\/
link
\.
js/
,
/next
\/
dist
\/
client
\/
link
\.
js/
,
],
notTests
:
[
/node_modules
\/
react
\/
cjs
\/
react
\.
development
\.
js/
],
},
{
page
:
'/counter'
,
tests
:
[
/webpack-runtime
\.
js/
,
/chunks
\/
.*
?\.
js/
,
/node_modules
\/
react
\/
index
\.
js/
,
/node_modules
\/
react
\/
package
\.
json/
,
/node_modules
\/
react
\/
cjs
\/
react
\.
production
\.
min
\.
js/
,
/next
\/
router
\.
js/
,
/next
\/
dist
\/
client
\/
router
\.
js/
,
],
notTests
:
[
/node_modules
\/
react
\/
cjs
\/
react
\.
development
\.
js/
],
},
{
{
page
:
'/next-import'
,
page
:
'/next-import'
,
tests
:
[
tests
:
[
...
...
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