简体   繁体   English

Angular2使用npm reflect-metadata或core-js / es7 / reflect

[英]Angular2 using either npm reflect-metadata or core-js/es7/reflect

Looking at Angular2 projects, I see some are using: npm reflect-metadata 看看Angular2项目,我看到一些正在使用:npm reflect-metadata

and others are using : core-js/es7/reflect 和其他人正在使用:core-js / es7 / reflect

I know both are implementing the ES7 proposed Decorator and reflect API 我知道两者都在实现ES7提议的Decorator并反映API

But what is the difference between the two? 但这两者有什么区别? Are they just copy/paste ? 它们只是复制/粘贴吗? I assume they are equivalent 我认为它们是等价的

core-js/es7/reflect: The native JavaScript support for a metadata reflection API . core-js/es7/reflect:元数据反射API的本机JavaScript支持。

npm reflect-metadata: The TypeScript support for the prototype of the ES7 Reflection API . npm reflect-metadata: 对ES7 Reflection API原型的 TypeScript支持。

Hope this help! 希望这有帮助!

暂无
暂无

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

相关问题 在IE中运行Angular 5应用程序,而无需使用“导入'core-js / es6 / reflect'和导入'core-js / es7 / reflect'” - Run Angular 5 app in IE without using “import 'core-js/es6/reflect' and import 'core-js/es7/reflect'” 将ES6与Angular2 rc3一起使用时,需要使用未捕获的反射元数据填充程序 - Uncaught reflect-metadata shim is required when using ES6 with Angular2 rc3 Angular2 RC-4迁移失败,带有反射元数据 - Angular2 RC-4 migration failing with reflect-metadata Angular2无法更新到RC7-zone.js和reflect-metadata - Angular2 Failing to update to RC7 - zone.js & reflect-metadata 如何使用Angular 2(beta和更新版本)加载RxJS(和zone.js / reflect-metadata)? - How to load RxJS (and zone.js / reflect-metadata) with Angular 2 (beta and newer)? Natviescript中的单元测试Angular:使用类装饰器时需要reflect-metadata shim - Unit Testing Angular in Natviescript: reflect-metadata shim is required when using class decorators SharePoint Framework中的反射元数据突然中断 - Reflect-metadata suddenly breaking in Sharepoint Framework 是否有任何用于导入ES6和ES7 core-js polyfill的用途? - Is there any use in importing both ES6 and ES7 core-js polyfills? 如何在 Systemjs 构建器任务中包含 zone.js、reflect-metadata 等? - How to include zone.js, reflect-metadata etc. in Systemjs builder task? 未在反射元数据上定义需求-__webpack_require__问题 - Require is not defined on reflect-metadata - __webpack_require__ issue
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM