Skip to content

Commit

Permalink
Use Prismic CDN URL in cms-prismic example (#26837)
Browse files Browse the repository at this point in the history
The CDN URL is the recommended URL for the Prismic REST and GraphQL APIs.

## Documentation / Examples

- [x] Make sure the linting passes
  • Loading branch information
angeloashmore authored Jul 2, 2021
1 parent a696596 commit b408999
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/cms-prismic/lib/api.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import Prismic from 'prismic-javascript'

const REPOSITORY = process.env.PRISMIC_REPOSITORY_NAME
const REF_API_URL = `https://${REPOSITORY}.prismic.io/api/v2`
const GRAPHQL_API_URL = `https://${REPOSITORY}.prismic.io/graphql`
const REF_API_URL = `https://${REPOSITORY}.cdn.prismic.io/api/v2`
const GRAPHQL_API_URL = `https://${REPOSITORY}.cdn.prismic.io/graphql`
// export const API_URL = 'https://your-repo-name.cdn.prismic.io/api/v2'
export const API_TOKEN = process.env.PRISMIC_API_TOKEN
export const API_LOCALE = process.env.PRISMIC_REPOSITORY_LOCALE
Expand Down

0 comments on commit b408999

Please sign in to comment.