0

data-smartedit-allow-origin如果应用程序托管在 CCV2 中,那么管理不同环境的最佳方法(在 index.html 中)是什么?目前,该值在 index.html 中被硬编码。对于我们的 Development Storefront,它指向 Development SmartEdit/Hybris。例如 data-smartedit-allow-origin="Development-URL"

如果我们有其他环境,例如登台和生产环境,怎么样?我们正在考虑将它们合并为 1,例如: data-smartedit-allow-origin="Development-URL,Staging-URL,Production-URL" 但是,这似乎并不理想。对于 Hybris,我们可以针对不同的环境使用不同的 local.properties 文件。(例如 local-dev.properties、local.prod.properties)

4

1 回答 1

0

Spartacus 团队目前的建议是“拥有一个一致的通配符值列表,适用于开发/暂存/产品”。例如 data-smartedit-allow-origin="*.company.com" 。这意味着开发店面可以允许其他环境的 SmartEdit。

参考:

于 2020-05-04T14:26:50.273 回答