mirror of
https://github.com/d0zingcat/nextjs-notion-starter-kit.git
synced 2026-05-13 15:09:47 +00:00
Document the Deployment Protection setting causing 401 Unauthorized for preview images in Vercel. fixes #435, fixes #437
This commit is contained in:
11
readme.md
11
readme.md
@@ -47,6 +47,7 @@ This project requires a recent version of Node.js (we recommend >= 16).
|
|||||||
3. `npm install`
|
3. `npm install`
|
||||||
4. `npm run dev` to test locally
|
4. `npm run dev` to test locally
|
||||||
5. `npm run deploy` to deploy to vercel 💪
|
5. `npm run deploy` to deploy to vercel 💪
|
||||||
|
6. ❗Disable **Deployment Protection** setting in Vercel Web Dashboard ❗ ([See more below](#vercel-configuration))
|
||||||
|
|
||||||
I tried to make configuration as easy as possible — All you really need to do to get started is edit `rootNotionPageId`.
|
I tried to make configuration as easy as possible — All you really need to do to get started is edit `rootNotionPageId`.
|
||||||
|
|
||||||
@@ -58,6 +59,16 @@ In order to find your Notion workspace ID (optional), just load any of your site
|
|||||||
|
|
||||||
I recommend setting up a collection on your home page that contains all of your articles / projects / content. There are no structural constraints on your Notion workspace, however, so feel free to add content as you normally would in Notion.
|
I recommend setting up a collection on your home page that contains all of your articles / projects / content. There are no structural constraints on your Notion workspace, however, so feel free to add content as you normally would in Notion.
|
||||||
|
|
||||||
|
### Vercel Configuration
|
||||||
|
#### Enabling social media preview images
|
||||||
|
**❗❗❗Social media preview images won't work by default in Vercel❗❗❗**
|
||||||
|
|
||||||
|
👉 You need Login to Vercel Dashboard and **disable Vercel Authentication** from `Project -> Settings -> Deployment Protection`.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
💡 If you forget to do this your site will return `401 Unauthorized` responses when crawlers are trying to retrieve the images
|
||||||
|
|
||||||
## URL Paths
|
## URL Paths
|
||||||
|
|
||||||
The app defaults to slightly different URL paths in dev vs prod (though pasting any dev pathname into prod will work and vice-versa).
|
The app defaults to slightly different URL paths in dev vs prod (though pasting any dev pathname into prod will work and vice-versa).
|
||||||
|
|||||||
Reference in New Issue
Block a user