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
d015bac6
Commit
d015bac6
authored
Feb 07, 2018
by
Scott Polhemus
Committed by
Arunoda Susiripala
Feb 07, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Copy static assets from .next folder when exporting (#3719)
* Copy .next/static directory when exporting * Use nextDir
parent
955cc827
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
export.js
server/export.js
+9
-0
No files found.
server/export.js
View file @
d015bac6
...
@@ -49,6 +49,15 @@ export default async function (dir, options, configuration) {
...
@@ -49,6 +49,15 @@ export default async function (dir, options, configuration) {
)
)
}
}
// Copy .next/static directory
if
(
existsSync
(
join
(
nextDir
,
'static'
)))
{
log
(
' copying "static build" directory'
)
await
cp
(
join
(
nextDir
,
'static'
),
join
(
outDir
,
'_next'
,
'static'
)
)
}
// Copy dynamic import chunks
// Copy dynamic import chunks
if
(
existsSync
(
join
(
nextDir
,
'chunks'
)))
{
if
(
existsSync
(
join
(
nextDir
,
'chunks'
)))
{
log
(
' copying dynamic import chunks'
)
log
(
' copying dynamic import chunks'
)
...
...
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