diff --git a/examples/with-stripe-typescript/README.md b/examples/with-stripe-typescript/README.md index e459e068641f8..ce92d0671f52c 100644 --- a/examples/with-stripe-typescript/README.md +++ b/examples/with-stripe-typescript/README.md @@ -107,4 +107,4 @@ After the successful deploy, Now will show you the URL for your site. Copy that now secrets rm stripe_webhook_secret now secrets add stripe_webhook_secret whsec_*** -As the secrets are pulled into the application at deploy time, we will need to redeploy our app after we made changes to the secrets. Run `now` again to redeploy with the new secret value. +As the secrets are set as env vars in the project at deploy time, we will need to redeploy our app after we made changes to the secrets. Run `now` again to redeploy with the new secret value. diff --git a/examples/with-stripe-typescript/next.config.js b/examples/with-stripe-typescript/next.config.js index c1fd14db22e84..604069d81a0c7 100644 --- a/examples/with-stripe-typescript/next.config.js +++ b/examples/with-stripe-typescript/next.config.js @@ -3,7 +3,5 @@ require('dotenv').config() module.exports = { env: { STRIPE_PUBLISHABLE_KEY: process.env.STRIPE_PUBLISHABLE_KEY, - STRIPE_SECRET_KEY: process.env.STRIPE_SECRET_KEY, - STRIPE_WEBHOOK_SECRET: process.env.STRIPE_WEBHOOK_SECRET, }, } diff --git a/examples/with-stripe-typescript/now.json b/examples/with-stripe-typescript/now.json index 19119c02f98cc..527e1aaee55be 100644 --- a/examples/with-stripe-typescript/now.json +++ b/examples/with-stripe-typescript/now.json @@ -1,9 +1,11 @@ { + "env": { + "STRIPE_SECRET_KEY": "@stripe_secret_key", + "STRIPE_WEBHOOK_SECRET": "@stripe_webhook_secret" + }, "build": { "env": { - "STRIPE_PUBLISHABLE_KEY": "@stripe_publishable_key", - "STRIPE_SECRET_KEY": "@stripe_secret_key", - "STRIPE_WEBHOOK_SECRET": "@stripe_webhook_secret" + "STRIPE_PUBLISHABLE_KEY": "@stripe_publishable_key" } } } diff --git a/examples/with-stripe-typescript/package.json b/examples/with-stripe-typescript/package.json index b519ad5073b27..35887c7c01e0a 100644 --- a/examples/with-stripe-typescript/package.json +++ b/examples/with-stripe-typescript/package.json @@ -1,7 +1,7 @@ { "name": "with-stripe-typescript", "version": "1.0.0", - "description": "Full-stack TypeScript sample using Next.js, react-stripe-js, and stripe-node.", + "description": "Full-stack TypeScript example using Next.js, react-stripe-js, and stripe-node.", "scripts": { "dev": "next", "build": "next build",