This is an SEO Metadata field widget, built on top of the JSON field type. It collects some basic data that we use for metadata when building pages.
- In contentful, create a new app with the name
SEO Field Widget
- Allow the app to use the Field location, for the JSON field type
- Upload the contents of the
./dist
directory from your codebase - Install the app to your space and environment
- On a page content type, create JSON field called SEO.
- Scroll down to the widget selection and choose SEO Fields.
- Save the field and content type.
In the project directory, you can run:
Creates or updates your app definition in Contentful, and runs the app in development mode. Open your app to view it in the browser.
The page will reload if you make edits. You will also see any lint errors in the console.
Builds the app for production to the build
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes. Your app is ready to be deployed!
Uploads the build folder to contentful and creates a bundle that is automatically activated. The command guides you through the deployment process and asks for all required arguments. Read here for more information about the deployment process.
Similar to npm run upload
it will upload your app to contentful and activate it. The only difference is
that with this command all required arguments are read from the environment variables, for example when you add
the upload command to your CI pipeline.
For this command to work, the following environment variables must be set:
CONTENTFUL_ORG_ID
- The ID of your organizationCONTENTFUL_APP_DEF_ID
- The ID of the app to which to add the bundleCONTENTFUL_ACCESS_TOKEN
- A personal access token