Hi everyone, I have a question:
Initially, my Shopify App was created through dashboard, without CLI, because it suited my needs at that time.
But now, since I’m working with Google Merchant Center and want to insert verification meta tag into website’s , I’ll need to utilize Theme app extension to insert app embed block that target the (I can’t use ScriptTag API because it only inject the tag at runtime, not at source code level, and Asset API is deprecated).
The problem is Theme app extension requires an app created from CLI, so I can’t attach that app embed block to my current app. I also can’t just create another new app, because we’ve been running that app for 2 years and many customers are using it.
So is there any way for me to:
-
Attach app embed block to the current app, or
-
Convert current app into a CLI one that won’t affect current customers linkage, or
-
Successfully insert and verify Google Merchant Center account automatically, without the need of customers doing that themselves.
Please help me. I’m at a dead-end here for 2 months already.
Thank you so much.
I’m confused here. Why can’t you use the Shopify CLI with this app? Are you getting error messages?
Based on the information provided, I’m assuming that your app is currently using the Asset API to inject code into stores.
If you want to migrate to a theme app extension, I would recommend this approach:
- Get your project to work with the CLI
- Add a new theme app extension, and make all new users use it instead of the Asset API approach
- Create a detailed migration guide for your existing customers to enable the new theme app extension in their themes, and to remove the old code that was injected by the Asset API
- Since most users are likely non-technical, prepare your support team to be able to perform this migration for customers
Hope this helps,
Tobe
1 Like
Initially, I created the app with the “dashboard method”, so there’s no CLI source code to add the new theme app extension.
And so my thought was to create a new Shopify CLI app as you suggested.
But since we don’t want any interaction from the customers, because our main attraction point to customers from the beginning is “connect to Shopify product seamlessly without touching the Admin page”, and also most of our customers are non-technical as you said, they will leave us if they hear about anything related to “go to Admin dashboard”.
That’s why I don’t want to create a whole new app, I’m looking for a way to convert the current dashboard app to a CLI one, or another way to insert the verification script from Google Merchant Center.
Oh and btw, I’m not using Asset API, because Shopify Exemption Request team told me I can do it through theme extension and won’t allow me to use Asset API.