jjzjj

SubService

全部标签

javascript - 具有 (ES6) 类和继承的 Angular.js DI

背景,我们应用程序中类/模块的当前实现是common.js和CoffeeScript类。我正在拼命寻找可以使用ES6或TypeScript的解决方案,但问题仍然存在。如何使用Angular-1.x通过类继承进行DI?给定代码://SuperService.jsclassSuperService{constructor($http,$q,$etc){//Implementationisnotimportant...}}export{SubService}//SubService.jsimport{SuperService}from'./SuperService';classSubServ