__GARFISH_EXPORTS__ 如何使用? #484
-
在文档 常见问题(https://www.garfishjs.org/issues/)中,第一个问题的其中异种解决方法“请试图通过环境变量导出,这将会让 Garfish 框架更准确的获取到导出内容”: if (window.GARFISH && typeof GARFISH_EXPORTS !== 'undefined') { 本人使用angular作为子项目,在main.ts引入上述代码会直接报错找不到__GARFISH_EXPORTS__ 。请问改如何引入此环境变量? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
ERROR in src/main.ts:51:45 - error TS2304: Cannot find name 'GARFISH_EXPORTS'. 51 if ((window as any).GARFISH && typeof GARFISH_EXPORTS !== 'undefined') { 53 GARFISH_EXPORTS.provider = provider; |
Beta Was this translation helpful? Give feedback.
-
可以参考我们 angular 的 实例: https://github.com/modern-js-dev/garfish/tree/main/dev |
Beta Was this translation helpful? Give feedback.
可以参考我们 angular 的 实例: https://github.com/modern-js-dev/garfish/tree/main/dev