We need to make a decision shortly on the best way to go about creating websites for new markets based off of our current website.
Current setup. We have one Gatsby codebase that we are in the progress of migrating to Next.js, because of the better integration with Prismic.
We also want to create a website for a new domain / country from the single code base, but with different content.
We are wondering what Prismic's recommendation for that is?
I did see this post from a Prismic Education member recommending separate Prismic repositories per website.
However our main concern is that we always need custom types to be in sync, for analytics and other reasons, and Prismic doesn't have the write API to make changes to custom types programatically.
And our content management team had concerns with organizing content in a single Prismic repository with several markets/ domains.
So if a Prismic member could recommend there best approach for
Single Code Base
Separate Website Builds with different content for different markets/domains.
Custom types must always be in sync.:
At the moment there's no way to automatically keep the Custom types in sync between repositories, so it is something that you'll need to do manually:
Separate Website Builds with different content for different markets/domains:
Our recommendation is that is better to have two separate repositories rather than 1 that is shared between multiple apps, so that the Documents are independent and if you or your team ever make an unexpected change in the Custom types you don't need to worry about breaking other apps
Single Code Base: Take a look at this Next.js thread where they discuss code sharing, this proposes to have a shared library between projects which sounds like a good solution.
Thanks for the reply!
I did see there is some push or write API functionality in progress with Slice Machine.
Do you see any possibility for updating custom types in Prismic programatically in the near future?
Having the possibility of managing Slices in Custom Types programmatically is kind of like the way Slice Machine already works. Because this allows you to modify your Slices in one place and after pushing your changes to Prismic and to Storybook you update these Slices everywhere in your project, you only need to template new fields.
Also, read about the Custom Types API
1 Like
Pau
closed , flag & select 'Something Else' to reopen.
10
This issue has been closed due to inactivity. Flag to reopen.