-
Notifications
You must be signed in to change notification settings - Fork 27k
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
Support custom .toJSON when serializing SSR props #12156
Support custom .toJSON when serializing SSR props #12156
Conversation
Stats from current PRDefault Server Mode (Decrease detected ✓)General Overall increase
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 12.9s | 12.6s | -237ms |
nodeModulesSize | 55.2 MB | 55.2 MB |
Page Load Tests Overall decrease ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.213 | 2.21 | 0 |
/ avg req/sec | 1129.8 | 1131.2 | |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.253 | 1.264 | |
/error-in-render avg req/sec | 1995.89 | 1978.42 | -17.47 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 929 B | 929 B | ✓ |
link.html gzip | 938 B | 938 B | ✓ |
withRouter.html gzip | 925 B | 925 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 13.5s | 13.4s | -91ms |
nodeModulesSize | 55.2 MB | 55.2 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 558 kB | 558 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 558 kB | 558 kB | |
link.js | 595 kB | 595 kB | |
routerDirect.js | 587 kB | 587 kB | |
withRouter.js | 587 kB | 587 kB | |
Overall change | 2.89 MB | 2.89 MB |
Otherwise, if JSON.stringify(...) were used the test would incorrectly pass.
Stats from current PRDefault Server Mode (Increase detected
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 11.7s | 11.8s | |
nodeModulesSize | 55.2 MB | 55.2 MB |
Page Load Tests Overall increase ✓
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 1.951 | 1.919 | -0.03 |
/ avg req/sec | 1281.7 | 1302.62 | |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 0.999 | 0.984 | -0.02 |
/error-in-render avg req/sec | 2502.88 | 2540.78 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 929 B | 929 B | ✓ |
link.html gzip | 939 B | 939 B | ✓ |
withRouter.html gzip | 925 B | 925 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 12.6s | 12.2s | -419ms |
nodeModulesSize | 55.2 MB | 55.2 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 558 kB | 558 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 558 kB | 558 kB | |
link.js | 595 kB | 595 kB | |
routerDirect.js | 587 kB | 587 kB | |
withRouter.js | 587 kB | 587 kB | |
Overall change | 2.89 MB | 2.89 MB |
Stats from current PRDefault Server Mode (Decrease detected ✓)General Overall increase
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 12.3s | 13.3s | |
nodeModulesSize | 55.2 MB | 55.2 MB |
Page Load Tests Overall decrease ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.242 | 2.28 | |
/ avg req/sec | 1114.87 | 1096.68 | -18.19 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.254 | 1.354 | |
/error-in-render avg req/sec | 1993.3 | 1845.77 | -147.53 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 929 B | 929 B | ✓ |
link.html gzip | 939 B | 939 B | ✓ |
withRouter.html gzip | 925 B | 925 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 13.6s | 13.8s | |
nodeModulesSize | 55.2 MB | 55.2 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.25 kB | 6.25 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..45d6.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.7 kB | 56.7 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.79 kB | 4.79 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.87 kB | 6.87 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.4 kB | 51.4 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 558 kB | 558 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 558 kB | 558 kB | |
link.js | 595 kB | 595 kB | |
routerDirect.js | 587 kB | 587 kB | |
withRouter.js | 587 kB | 587 kB | |
Overall change | 2.89 MB | 2.89 MB |
🤔 Unsure why the serverless mode has a size increase. Happy to debug it, though it could be the additional test in development mode with |
Failing test suitestest/integration/size-limit/test/index.test.js
Expand output● Production response size › should not increase the overall response size of default build
|
Stats from current PRDefault Server Mode (Decrease detected ✓)General Overall increase
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 12.7s | 12.2s | -487ms |
nodeModulesSize | 55.2 MB | 55.2 MB |
Page Load Tests Overall decrease ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.027 | 2.018 | -0.01 |
/ avg req/sec | 1233.51 | 1238.65 | |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.052 | 1.062 | |
/error-in-render avg req/sec | 2376.17 | 2353.43 | -22.74 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.27 kB | 6.27 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..ac5e.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.8 kB | 56.8 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.82 kB | 4.82 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.5 kB | 51.5 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 927 B | 927 B | ✓ |
link.html gzip | 937 B | 937 B | ✓ |
withRouter.html gzip | 926 B | 926 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 13.3s | 13s | -299ms |
nodeModulesSize | 55.2 MB | 55.2 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.27 kB | 6.27 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..ac5e.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 56.8 kB | 56.8 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.82 kB | 4.82 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
Overall change | 51.5 kB | 51.5 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.2 kB | 26.2 kB | ✓ |
Overall change | 26.2 kB | 26.2 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.12 kB | 3.12 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.85 kB | 7.85 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 558 kB | 558 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 558 kB | 558 kB | |
link.js | 595 kB | 595 kB | |
routerDirect.js | 587 kB | 587 kB | |
withRouter.js | 587 kB | 587 kB | |
Overall change | 2.89 MB | 2.89 MB |
I'm going to investigate https://github.com/zeit/next.js/blob/canary/test/integration/size-limit/test/index.test.js & diff the output to determine what the increase actually is. |
Stats from current PRDefault Server Mode (Decrease detected ✓)General Overall increase
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 12.7s | 13s | |
nodeModulesSize | 55.2 MB | 55.2 MB |
Page Load Tests Overall decrease ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.292 | 2.176 | -0.12 |
/ avg req/sec | 1090.66 | 1148.88 | |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.262 | 1.302 | |
/error-in-render avg req/sec | 1981.13 | 1920.74 | -60.39 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.26 kB | 6.26 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..e8e1.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39.2 kB | 39.2 kB | ✓ |
Overall change | 56.9 kB | 56.9 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.81 kB | 4.81 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39.2 kB | 39.2 kB | ✓ |
Overall change | 51.7 kB | 51.7 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.3 kB | 26.3 kB | ✓ |
Overall change | 26.3 kB | 26.3 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.15 kB | 3.15 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.88 kB | 7.88 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 927 B | 927 B | ✓ |
link.html gzip | 937 B | 937 B | ✓ |
withRouter.html gzip | 925 B | 925 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 13.6s | 14s | |
nodeModulesSize | 55.2 MB | 55.2 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.26 kB | 6.26 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..e8e1.js gzip | 10.3 kB | 10.3 kB | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.a1..NSE.txt gzip | 220 B | 220 B | ✓ |
framework.HASH.js gzip | 39.2 kB | 39.2 kB | ✓ |
Overall change | 56.9 kB | 56.9 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 4.81 kB | 4.81 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39.2 kB | 39.2 kB | ✓ |
Overall change | 51.7 kB | 51.7 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.3 kB | 26.3 kB | ✓ |
Overall change | 26.3 kB | 26.3 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.23 kB | 1.23 kB | ✓ |
_error.js gzip | 3.15 kB | 3.15 kB | ✓ |
hooks.js gzip | 663 B | 663 B | ✓ |
index.js gzip | 222 B | 222 B | ✓ |
link.js gzip | 2.06 kB | 2.06 kB | ✓ |
routerDirect.js gzip | 280 B | 280 B | ✓ |
withRouter.js gzip | 278 B | 278 B | ✓ |
Overall change | 7.88 kB | 7.88 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 598 B | 598 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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 | 279 B | 279 B | ✓ |
withRouter.m..dule.js gzip | 278 B | 278 B | ✓ |
Overall change | 5.37 kB | 5.37 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 557 kB | 558 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 557 kB | 558 kB | |
link.js | 595 kB | 595 kB | |
routerDirect.js | 587 kB | 588 kB | |
withRouter.js | 588 kB | 588 kB | |
Overall change | 2.89 MB | 2.89 MB |
Failing test suitestest/integration/getserversideprops/test/index.test.js
Expand output● getServerSideProps › serverless mode › should output routes-manifest correctly
● getServerSideProps › production mode › should output routes-manifest correctly
|
Stats from current PRDefault Server Mode (Decrease detected ✓)General Overall increase
|
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 13.3s | 13.5s | |
nodeModulesSize | 60.4 MB | 60.4 MB |
Page Load Tests Overall decrease ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.186 | 2.236 | |
/ avg req/sec | 1143.58 | 1118.12 | -25.46 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.473 | 1.498 | |
/error-in-render avg req/sec | 1696.87 | 1668.82 | -28.05 |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.71 kB | 6.71 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..fc14.js gzip | 10.5 kB | 10.5 kB | ✓ |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
Overall change | 57.1 kB | 57.1 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 5.74 kB | 5.74 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
Overall change | 52.5 kB | 52.5 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.3 kB | 26.3 kB | ✓ |
Overall change | 26.3 kB | 26.3 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.26 kB | 1.26 kB | ✓ |
_error.js gzip | 3.28 kB | 3.28 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.26 kB | 8.26 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 604 B | 604 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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.38 kB | 5.38 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | 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
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
index.html gzip | 927 B | 927 B | ✓ |
link.html gzip | 937 B | 937 B | ✓ |
withRouter.html gzip | 924 B | 924 B | ✓ |
Overall change | 2.79 kB | 2.79 kB | ✓ |
Serverless Mode (Increase detected ⚠️ )
General Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
buildDuration | 14s | 14.2s | |
nodeModulesSize | 60.4 MB | 60.4 MB |
Client Bundles (main, webpack, commons)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.js gzip | 6.71 kB | 6.71 kB | ✓ |
webpack-HASH.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..fc14.js gzip | 10.5 kB | 10.5 kB | ✓ |
framework.HASH.js gzip | 39.1 kB | 39.1 kB | ✓ |
Overall change | 57.1 kB | 57.1 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
main-HASH.module.js gzip | 5.74 kB | 5.74 kB | ✓ |
webpack-HASH..dule.js gzip | 746 B | 746 B | ✓ |
de003c3a9d30..dule.js gzip | 6.88 kB | 6.88 kB | ✓ |
framework.HA..dule.js gzip | 39.1 kB | 39.1 kB | ✓ |
Overall change | 52.5 kB | 52.5 kB | ✓ |
Legacy Client Bundles (polyfills)
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
polyfills-HASH.js gzip | 26.3 kB | 26.3 kB | ✓ |
Overall change | 26.3 kB | 26.3 kB | ✓ |
Client Pages
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.js gzip | 1.26 kB | 1.26 kB | ✓ |
_error.js gzip | 3.28 kB | 3.28 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.26 kB | 8.26 kB | ✓ |
Client Pages Modern
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_app.module.js gzip | 604 B | 604 B | ✓ |
_error.module.js gzip | 2.09 kB | 2.09 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.38 kB | 5.38 kB | ✓ |
Client Build Manifests
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_buildManifest.js gzip | 61 B | 61 B | ✓ |
_buildManife..dule.js gzip | 61 B | 61 B | ✓ |
Overall change | 122 B | 122 B | ✓ |
Serverless bundles Overall increase ⚠️
zeit/next.js canary | ericclemmons/next.js 11993-getServerSideProps-toJSON | Change | |
---|---|---|---|
_error.js | 851 kB | 851 kB | |
404.html | 4.18 kB | 4.18 kB | ✓ |
hooks.html | 3.81 kB | 3.81 kB | ✓ |
index.js | 851 kB | 851 kB | |
link.js | 888 kB | 888 kB | |
routerDirect.js | 880 kB | 881 kB | |
withRouter.js | 881 kB | 881 kB | |
Overall change | 4.36 MB | 4.36 MB |
Failing test suitestest/integration/getserversideprops/test/index.test.js
Expand output● getServerSideProps › serverless mode › should output routes-manifest correctly
● getServerSideProps › production mode › should output routes-manifest correctly
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-
It's not clear to me why
toJSON
wouldn't be allowed to return astring
. IMO, any valid JSON output here would be accepted. -
This isn't called on the server-side, so there's still the possibility of a hydration mismatch. Especially if
toJSON
selectively plucks fields.
Are we sure something like this is necessary? I think it'd be better handled by doing a .map()
across your results array in getServerSideProps
.
@Timer Thanks for getting around to this. Your comments aren't associated with code, so I'll do the best I can to infer:
This restriction can be loosened. The tests already accounted for JSON.stringify(new Date())
"\"2020-05-22T22:04:30.915Z\"" See: #11993 (comment),
What part's not called on the server-side?
When you own the models, yes, See: #11993 (comment) |
|
Since adding this feature would require we run it server-side, I'm not sure it's worth doing so. For larger objects, this could introduce significant latency in production mode. Users who bump into this should use Thank you for the PR. Could you send a PR updating our documentation explaining this? |
I’m confused: I tested this fork using my SSR code, so it’s as if this
check already happens.
And it’s purely opt-in, especially for library authors.
What am I missing?
On Sat, May 23, 2020 at 1:30 PM Joe Haddad ***@***.***> wrote:
Since adding this feature would require we run it server-side, I'm not
sure it's worth doing so. For larger objects, this could introduce
significant latency in production mode. Users who bump into this should use
.map.
Thank you for the PR.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#12156 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAADWTUOUM7EMVMRR6JKPTTRTAW4XANCNFSM4MPTMQ5A>
.
--
Sent from Gmail Mobile
|
The check happens in development in order to make sure you don't introduce hydration bugs that you can't track down easily (as explained earlier) however serialization is only ran to create the JSON string included in the |
We're currently using a custom |
@Timer @timneutkens I don't think this is true for my PR. This PR explicitly only checks for the In fact, this PR even validates that the Can you reconsider this PR and what it would take to allow this? |
The serialized result will differ in production mode when the serialization check is not called. You can see that happen when you run this:
And open http://localhost:3000/to-json. The server-side result will differ from the client-side result. Potentially the overhead of running the serialization could be worth it but you'd have to do a deeper investigation of what the impact of that is on applications with a lot of data. Potentially the result of serializing could be passed to |
When returning class-based instances as
props
, users experience an errorAs a way to opt-in to serialization (vs. requiring users to run
JSON.parse(JSON.stringify(...))
, this PR leverages the existing support for.toJSON
.This PR enforces the following contracts:
.toJSON()
must return a plain object, since the expectation is that a class-based instance would return enumerable properties but without the instance. (e.g.Post { title: "Post #1 " }
becomes{ title: "Post #1" }
).This is necessary for pathing to be consistent on both the server & client (e.g.
post.title
works on bothPost
instances and plain objects)Date.toJSON()
continues to throw, since it returns a string.Fixes #11993