简体   繁体   中英

Is Barrel (index.ts) deprecated from Angular 6?

In Angular2, we made use of index.ts files extensively to make the import and export statements simpler.

Since we are upgrading to Angular6 , getting a lot of circular dependency issues. The moment we remove or ignore these index.ts files, then all those dependency issues are getting resolved.

So we would like to know that, is Barrel (index.ts) no more used in Angular6?

If still getting used, then is there any changes, the way it was used before?

它们不被弃用,只是不要从同一目录中引用它们,这意味着不要从导出当前文件的桶中导入符号,而从文件本身导入

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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