how can my app modify the shop's template files

亡梦爱人 提交于 2019-12-22 10:31:39

问题


I need to inject liquid markup to the store's theme templates when my app is installed. I know there are ScriptTags, but they load scripts. And I know that the scripts can change the page's DOM. but I need to install my liquid to the product details pages. is it possible?


回答1:


I would add your Liquid as a new snippet asset. The merchant can then be instructed to paste a Liquid include statement you provide them in their product Liquid scripts.

That is fairly clean. Otherwise, your App could download their product Liquid script, edit it, and then add it to the shop as an alternative template. You could then instruct the merchant to render their products with the alternative template.

I am sure there are other possibilities too.



来源:https://stackoverflow.com/questions/12265070/how-can-my-app-modify-the-shops-template-files

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!