Can I use Next.js frontend app as Block in Shopify's Theme App Extensions instead of liquid?

288 views Asked by At

I have a frontend developed using Next.js in which I consumed Storyblok API to get dynamic content.

I want to use it as a Block in Theme App Extension instead of refactoring the code into liquid

Is that possible?

I really appreciate any help you can provide

Ps:

  • If there is a better way to do that let me know
  • I tried adding it as IFrame but it is not recommended for SEO and performance
1

There are 1 answers

0
David Lazar On

Go for it. You can do whatever you want in a block. You control the HTML(Liquid), JS, and CSS.

Note that you are probably killing a fly with a sledgehammer but that is your burden to bear. If your block is somehow slow or in-efficient, it'll show, but maybe it'll be zippy and great. Just throw down the code and see what happens. Should not take you more than a few minutes to establish whether you like it or not.