From 0648c355089ae3fd6159848acd5476b2c39fffc8 Mon Sep 17 00:00:00 2001 From: JJ Kasper Date: Fri, 10 Apr 2020 05:31:19 -0500 Subject: [PATCH] Update auto export opt-out warning and err.sh (#11801) --- errors/opt-out-auto-static-optimization.md | 2 +- packages/next/build/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/errors/opt-out-auto-static-optimization.md b/errors/opt-out-auto-static-optimization.md index afe98e98df4ef..d4445d444bee3 100644 --- a/errors/opt-out-auto-static-optimization.md +++ b/errors/opt-out-auto-static-optimization.md @@ -4,7 +4,7 @@ You are using `getInitialProps` in your [Custom ``](https://nextjs.org/docs#custom-app). -This causes **all pages** to be executed on the server -- disabling [Automatic Static Optimization](https://nextjs.org/docs#automatic-static-optimization). +This causes **all non-getStaticProps pages** to be executed on the server -- disabling [Automatic Static Optimization](https://nextjs.org/docs#automatic-static-optimization). #### Possible Ways to Fix It diff --git a/packages/next/build/index.ts b/packages/next/build/index.ts index e18487662c46d..f6307e5ab48e3 100644 --- a/packages/next/build/index.ts +++ b/packages/next/build/index.ts @@ -525,7 +525,7 @@ export default async function build(dir: string, conf = null): Promise { console.warn( chalk.bold.yellow(`Warning: `) + chalk.yellow( - `You have opted-out of Automatic Static Optimization due to \`getInitialProps\` in \`pages/_app\`.` + `You have opted-out of Automatic Static Optimization due to \`getInitialProps\` in \`pages/_app\`. This does not opt-out pages with \`getStaticProps\`` ) ) console.warn(