简体   繁体   English

什么是ember-engine的开发人员流程?

[英]What is the developer flow for ember-engines?

I am just beginning to look into Ember.js engines. 我刚刚开始研究Ember.js引擎。 One thing that stands out is that for every change I make in the engine code I need to re-install it into the host application. 有一点值得注意的是,对于我在引擎代码中所做的每一项更改,我都需要将其重新安装到主机应用程序中。 There is no live reload, rebuild or any of this. 没有实时重新加载,重建或任何此类。

Is there a way to smooth out this flow as it would slow down development considerably. 有没有办法消除这种流动,因为它会大大减缓开发速度。

The trick is to set isDevelopingAddon like so in the index.js file for the addon and use NPM link to get it into the main application node_packages folder - you will then get live reload, etc-: 诀窍是在index.js文件中为addon设置isDevelopingAddon ,并使用NPM链接将其导入主应用程序node_packages文件夹 - 然后您将获得实时重新加载,等等 - :

// Addon index.js
isDevelopingAddon: function() {
  return true;
}

To add to this I found an interesting article here: Ember and Yarn Workspaces 除此之外,我在这里找到了一篇有趣的文章: Ember和Yarn Workspaces

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM