Run the Prismic Slice Machine setup command
These docs rely on Slice Machine, which is in active development and subject to change. Content Relationships are not currently supported with Slices.
Before you run the Slice Machine command, make sure you have the correct version of:
The basic Slice Machine command
prismic sm --setup
What does this command do?
This command does a lot of different things for you including:
- This option on the command will automatically connect our default Component Library and add any dependencies necessary to use the tool. This is done by adding extra configurations to your next.config.js file.
- Adding the sm.json file with the default configuration.
- Adding the sm-resolver.json file.
- Creating a Prismic repository, with a standard "Page" custom type. You should receive a confirmation email and you can see your new repo by following link from email or by going directly to Prismic.
- Installing dependencies required by Slice Machine and the library you selected, like node-sass, sass-loader and essential-slices
- Installing libraries to fetch and display Prismic data like @prismicio/client, next-slicezone and next.
What is the Prismic repository?
This is where all your content for your project will be kept and where you can choose the content models (Slices) that will correspond to your component in the frontend of your project. You can learn more about Prismic here.