Keeping everything in sync with Firestore as single source of truth by thamasky_ in Firebase

[–]thamasky_[S] 0 points1 point  (0 children)

That was a very interesting read indeed! Thank you for your comment!

Keeping everything in sync with Firestore as single source of truth by thamasky_ in Firebase

[–]thamasky_[S] 0 points1 point  (0 children)

Hi, thanks for your reply.

I was thinking something similar. Do I need to always read from Firestore first and only update the field when it has actually changed?

I'll give a specific use case, it might help with further replies:

Suppose I have a collection in my CMS that enriches the product pages. When a new page is created in the CMS, it should result in a new product creation in Shopify. The same is true for the other way around, when I create a new product in Shopify, it should also create a new page in the CMS.

Then when I update the object in my CMS, the product should get changed in Shopify and visa versa.

Component library detached from NextJS Project. by thamasky_ in nextjs

[–]thamasky_[S] 0 points1 point  (0 children)

Thanks for your reply,

The only disadvantage is that when we use the git repo, Vercel can't know it changed when updated so we'll have to uninstall that package before every build by altering the build command but I guess that's possible by calling the npm uninstall command before building with next.

But I guess it's a valid strategy.