typings install dt~angular --global --save异常

前端之家收集整理的这篇文章主要介绍了typings install dt~angular --global --save异常前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

一、在使用VS Code添加angularjs智能提示出现异常

命令:

typings install dt~angular --global --save
异常如下:

typings ERR! message Attempted to compile "angular" as a global module,but it looks like an external module. You'll need to remove the global option to continue.

但去掉--global可以安装成功

typings install dt~angular --save 

还是会出异常没法使用。



解决方案:

对于dt~angular使用npm install @types/angular 命令安装


生成结果:


测试如下:



更多:

NodeJs开发环境搭建之Visual Studio Code

VS Code智能提示功能之Typings

NodeJs的安装和环境变量配置

原文链接:https://www.f2er.com/angularjs/148028.html

猜你在找的Angularjs相关文章