I am getting the error messages Module "ng" has no exported member
on all of my typings in visual studio code
My typing are were working 100% until i added angular-ui-router. I am not sure if this is the problem but i only noticed it after adding that.
In my .d.ts
files i get a specific error on angular
itself.
My tsd.json
looks like this
{
"version": "v4",
"repo": "borisyankov/DefinitelyTyped",
"ref": "master",
"path": "typings",
"bundle": "typings/tsd.d.ts",
"installed": {
"angular-material/angular-material.d.ts": {
"commit": "5a8fc5ee71701431e4fdbb80c506e3c13f85a9ff"
},
"jquery/jquery.d.ts": {
"commit": "40c60850ad6c8175a62d5ab48c4e016ea5b3dffe"
},
"angularjs/angular.d.ts": {
"commit": "40c60850ad6c8175a62d5ab48c4e016ea5b3dffe"
},
"angularjs/angular-route.d.ts": {
"commit": "5a8fc5ee71701431e4fdbb80c506e3c13f85a9ff"
},
"angularjs/angular-cookies.d.ts": {
"commit": "5a8fc5ee71701431e4fdbb80c506e3c13f85a9ff"
},
"angularjs/angular-animate.d.ts": {
"commit": "5a8fc5ee71701431e4fdbb80c506e3c13f85a9ff"
},
"angularjs/angular-resource.d.ts": {
"commit": "40c60850ad6c8175a62d5ab48c4e016ea5b3dffe"
},
"angular-ui-router/angular-ui-router.d.ts": {
"commit": "40c60850ad6c8175a62d5ab48c4e016ea5b3dffe"
}
}
}
I am a bit lost to what i have or have not done to mess this up. The weird thing is that everything still works 100%. So i am still getting intellsense for ng.
It just says that there are errors and everytime i build i am getting multiply errors on all the files.
Update
I ended up commenting out import ng = angular;
on line 17
and then changing ng.auto.IInjectorService;
to angular.auto.IInjectorService;
on line 173
in angular.d.ts
This means that every reference in the angular app is now made with angular
and not ng
, which is not ideal but it will do for now. I am pretty sure this is not a "best practice" fix .
https://github.com/DefinitelyTyped/DefinitelyTyped/issues/7284