Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix with antd ssg #13611

Merged
merged 4 commits into from
Jun 1, 2020
Merged

Fix with antd ssg #13611

merged 4 commits into from
Jun 1, 2020

Conversation

todortotev
Copy link
Contributor

@todortotev todortotev commented May 31, 2020

Closes #12664
Closes #13604

The culprit was not only changing the library directory, but also having the icons version past 4.0.6. Also, the components which used the library had to be adjusted according to the new changes.

Confirmed that it works both in production and development. Confirmed that it builds on dev and production.

Alt Text

@todortotev todortotev requested review from lfades and Timer as code owners May 31, 2020 15:37
Comment on lines +22 to +25
"browser": {
"fs": false,
"path": false
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this for?

Copy link

@webbertakken webbertakken Jun 1, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shameless copy paste from my repo lol. This is not actually needed for the example.

Copy link
Member

@lfades lfades left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

@ijjk
Copy link
Member

ijjk commented Jun 1, 2020

Stats from current PR

Default Server Mode (Decrease detected ✓)
General
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
buildDuration 13.7s 13.9s ⚠️ +202ms
nodeModulesSize 65.2 MB 65.2 MB
Page Load Tests Overall decrease ⚠️
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
/ failed reqs 0 0
/ total time (seconds) 2.401 2.438 ⚠️ +0.04
/ avg req/sec 1041.23 1025.38 -15.85
/error-in-render failed reqs 0 0
/error-in-render total time (seconds) 1.476 1.556 ⚠️ +0.08
/error-in-render avg req/sec 1693.88 1606.35 -87.53
Client Bundles (main, webpack, commons)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.js gzip 6.59 kB 6.59 kB
webpack-HASH.js gzip 746 B 746 B
de003c3a9d30..21ef.js gzip 10.5 kB 10.5 kB
framework.HASH.js gzip 39.1 kB 39.1 kB
Overall change 57 kB 57 kB
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.module.js gzip 5.67 kB 5.67 kB
webpack-HASH..dule.js gzip 746 B 746 B
de003c3a9d30..dule.js gzip 6.93 kB 6.93 kB
framework.HA..dule.js gzip 39.1 kB 39.1 kB
Overall change 52.5 kB 52.5 kB
Legacy Client Bundles (polyfills)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
polyfills-HASH.js gzip 26.3 kB 26.3 kB
Overall change 26.3 kB 26.3 kB
Client Pages
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.js gzip 1.26 kB 1.26 kB
_error.js gzip 3.25 kB 3.25 kB
hooks.js gzip 881 B 881 B
index.js gzip 222 B 222 B
link.js gzip 2.06 kB 2.06 kB
routerDirect.js gzip 279 B 279 B
withRouter.js gzip 278 B 278 B
Overall change 8.22 kB 8.22 kB
Client Pages Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.module.js gzip 604 B 604 B
_error.module.js gzip 2.04 kB 2.04 kB
hooks.module.js gzip 383 B 383 B
index.module.js gzip 223 B 223 B
link.module.js gzip 1.52 kB 1.52 kB
routerDirect..dule.js gzip 281 B 281 B
withRouter.m..dule.js gzip 278 B 278 B
Overall change 5.33 kB 5.33 kB
Client Build Manifests
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_buildManifest.js gzip 61 B 61 B
_buildManife..dule.js gzip 61 B 61 B
Overall change 122 B 122 B
Rendered Page Sizes
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
index.html gzip 926 B 926 B
link.html gzip 935 B 935 B
withRouter.html gzip 923 B 923 B
Overall change 2.78 kB 2.78 kB

Serverless Mode
General
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
buildDuration 14.6s 14.4s -128ms
nodeModulesSize 65.2 MB 65.2 MB
Client Bundles (main, webpack, commons)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.js gzip 6.59 kB 6.59 kB
webpack-HASH.js gzip 746 B 746 B
de003c3a9d30..21ef.js gzip 10.5 kB 10.5 kB
framework.HASH.js gzip 39.1 kB 39.1 kB
Overall change 57 kB 57 kB
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.module.js gzip 5.67 kB 5.67 kB
webpack-HASH..dule.js gzip 746 B 746 B
de003c3a9d30..dule.js gzip 6.93 kB 6.93 kB
framework.HA..dule.js gzip 39.1 kB 39.1 kB
Overall change 52.5 kB 52.5 kB
Legacy Client Bundles (polyfills)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
polyfills-HASH.js gzip 26.3 kB 26.3 kB
Overall change 26.3 kB 26.3 kB
Client Pages
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.js gzip 1.26 kB 1.26 kB
_error.js gzip 3.25 kB 3.25 kB
hooks.js gzip 881 B 881 B
index.js gzip 222 B 222 B
link.js gzip 2.06 kB 2.06 kB
routerDirect.js gzip 279 B 279 B
withRouter.js gzip 278 B 278 B
Overall change 8.22 kB 8.22 kB
Client Pages Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.module.js gzip 604 B 604 B
_error.module.js gzip 2.04 kB 2.04 kB
hooks.module.js gzip 383 B 383 B
index.module.js gzip 223 B 223 B
link.module.js gzip 1.52 kB 1.52 kB
routerDirect..dule.js gzip 281 B 281 B
withRouter.m..dule.js gzip 278 B 278 B
Overall change 5.33 kB 5.33 kB
Client Build Manifests
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_buildManifest.js gzip 61 B 61 B
_buildManife..dule.js gzip 61 B 61 B
Overall change 122 B 122 B
Serverless bundles
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_error.js 877 kB 877 kB
404.html 4.18 kB 4.18 kB
hooks.html 3.81 kB 3.81 kB
index.js 877 kB 877 kB
link.js 915 kB 915 kB
routerDirect.js 907 kB 907 kB
withRouter.js 907 kB 907 kB
Overall change 4.49 MB 4.49 MB

@ijjk
Copy link
Member

ijjk commented Jun 1, 2020

Stats from current PR

Default Server Mode (Decrease detected ✓)
General
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
buildDuration 14s 13.9s -75ms
nodeModulesSize 65.2 MB 65.2 MB
Page Load Tests Overall decrease ⚠️
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
/ failed reqs 0 0
/ total time (seconds) 2.466 2.439 -0.03
/ avg req/sec 1013.9 1024.91 ⚠️ +11.01
/error-in-render failed reqs 0 0
/error-in-render total time (seconds) 1.569 1.609 ⚠️ +0.04
/error-in-render avg req/sec 1593.12 1553.32 -39.8
Client Bundles (main, webpack, commons)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.js gzip 6.59 kB 6.59 kB
webpack-HASH.js gzip 746 B 746 B
de003c3a9d30..21ef.js gzip 10.5 kB 10.5 kB
framework.HASH.js gzip 39.1 kB 39.1 kB
Overall change 57 kB 57 kB
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.module.js gzip 5.67 kB 5.67 kB
webpack-HASH..dule.js gzip 746 B 746 B
de003c3a9d30..dule.js gzip 6.93 kB 6.93 kB
framework.HA..dule.js gzip 39.1 kB 39.1 kB
Overall change 52.5 kB 52.5 kB
Legacy Client Bundles (polyfills)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
polyfills-HASH.js gzip 26.3 kB 26.3 kB
Overall change 26.3 kB 26.3 kB
Client Pages
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.js gzip 1.26 kB 1.26 kB
_error.js gzip 3.25 kB 3.25 kB
hooks.js gzip 881 B 881 B
index.js gzip 222 B 222 B
link.js gzip 2.06 kB 2.06 kB
routerDirect.js gzip 279 B 279 B
withRouter.js gzip 278 B 278 B
Overall change 8.22 kB 8.22 kB
Client Pages Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.module.js gzip 604 B 604 B
_error.module.js gzip 2.04 kB 2.04 kB
hooks.module.js gzip 383 B 383 B
index.module.js gzip 223 B 223 B
link.module.js gzip 1.52 kB 1.52 kB
routerDirect..dule.js gzip 281 B 281 B
withRouter.m..dule.js gzip 278 B 278 B
Overall change 5.33 kB 5.33 kB
Client Build Manifests
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_buildManifest.js gzip 61 B 61 B
_buildManife..dule.js gzip 61 B 61 B
Overall change 122 B 122 B
Rendered Page Sizes
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
index.html gzip 926 B 926 B
link.html gzip 935 B 935 B
withRouter.html gzip 923 B 923 B
Overall change 2.78 kB 2.78 kB

Serverless Mode
General
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
buildDuration 14.8s 15s ⚠️ +118ms
nodeModulesSize 65.2 MB 65.2 MB
Client Bundles (main, webpack, commons)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.js gzip 6.59 kB 6.59 kB
webpack-HASH.js gzip 746 B 746 B
de003c3a9d30..21ef.js gzip 10.5 kB 10.5 kB
framework.HASH.js gzip 39.1 kB 39.1 kB
Overall change 57 kB 57 kB
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
main-HASH.module.js gzip 5.67 kB 5.67 kB
webpack-HASH..dule.js gzip 746 B 746 B
de003c3a9d30..dule.js gzip 6.93 kB 6.93 kB
framework.HA..dule.js gzip 39.1 kB 39.1 kB
Overall change 52.5 kB 52.5 kB
Legacy Client Bundles (polyfills)
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
polyfills-HASH.js gzip 26.3 kB 26.3 kB
Overall change 26.3 kB 26.3 kB
Client Pages
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.js gzip 1.26 kB 1.26 kB
_error.js gzip 3.25 kB 3.25 kB
hooks.js gzip 881 B 881 B
index.js gzip 222 B 222 B
link.js gzip 2.06 kB 2.06 kB
routerDirect.js gzip 279 B 279 B
withRouter.js gzip 278 B 278 B
Overall change 8.22 kB 8.22 kB
Client Pages Modern
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_app.module.js gzip 604 B 604 B
_error.module.js gzip 2.04 kB 2.04 kB
hooks.module.js gzip 383 B 383 B
index.module.js gzip 223 B 223 B
link.module.js gzip 1.52 kB 1.52 kB
routerDirect..dule.js gzip 281 B 281 B
withRouter.m..dule.js gzip 278 B 278 B
Overall change 5.33 kB 5.33 kB
Client Build Manifests
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_buildManifest.js gzip 61 B 61 B
_buildManife..dule.js gzip 61 B 61 B
Overall change 122 B 122 B
Serverless bundles
vercel/next.js canary TodorTotev/next.js fix-with-antd-ssg Change
_error.js 877 kB 877 kB
404.html 4.18 kB 4.18 kB
hooks.html 3.81 kB 3.81 kB
index.js 877 kB 877 kB
link.js 915 kB 915 kB
routerDirect.js 907 kB 907 kB
withRouter.js 907 kB 907 kB
Overall change 4.49 MB 4.49 MB

@Timer Timer added this to the 9.4.5 milestone Jun 1, 2020
@Timer Timer added the examples Issue was opened via the examples template. label Jun 1, 2020
@kodiakhq kodiakhq bot merged commit 795d931 into vercel:canary Jun 1, 2020
rokinsky pushed a commit to rokinsky/next.js that referenced this pull request Jul 11, 2020
Closes vercel#12664 
Closes vercel#13604 

The culprit was not only changing the library directory, but also having the icons version past 4.0.6. Also, the components which used the library had to be adjusted according to the new changes.

Confirmed that it works both in production and development. Confirmed that it builds on dev and production.

![Alt Text](https://media.giphy.com/media/dZ46aA1Rs7Oi1wSQKU/giphy.gif)
@vercel vercel locked as resolved and limited conversation to collaborators Jan 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
examples Issue was opened via the examples template.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

with-ant-design example not working with SSG on production
5 participants