angular – 如何获取最新版本的专用打字包

前端之家收集整理的这篇文章主要介绍了angular – 如何获取最新版本的专用打字包前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
在一个示例项目中,当我尝试打字安装以下typings.js我收到警告.我们如何获得最新的版本号以及symbole之后的数字是多少

{
  "globalDependencies": {
    "core-js": "registry:dt/core-js#0.0.0+20160725163759","jasmine": "registry:dt/jasmine#2.2.0+20160621224255","node": "registry:dt/node#6.0.0+20160909174046"
  }
}

typings WARN deprecated 10/7/2016:
“registry:dt/node#6.0.0+20160909174046” is deprecated (updated,
replaced or removed) typings WARN deprecated 10/4/2016:
“registry:dt/jasmine#2.2.0+20160621224255” is deprecated (updated,
replaced or removed) typings WARN deprecated 9/14/2016:
“registry:dt/core-js#0.0.0+20160725163759” is deprecated (updated,
replaced or removed)

+– core-js (global)
+– jasmine (global) `– node (global)

解决方法

跳过版本后缀#xxxxxxx将安装最新版本:

{
  "globalDependencies": {
    "core-js": "registry:dt/core-js","jasmine": "registry:dt/jasmine","node": "registry:dt/node"
  }
}

使用typings info dt~< package> –version找到dt包的版本:

> typings info dt~node --versions                                                       
TAG                    VERSION DESCRIPTION COMPILER LOCATION                                                                                             UPDATED                                                                       
6.0.0+20161006230116   6.0.0                        github:DefinitelyTyped/DefinitelyTyped/node/node.d.ts#38f26299ffa6ed4898e1dad4936b4ac6c6c66096       2016-10-06T23:01:16.000Z
0.12.0+20160906152630  0.12.0                       github:DefinitelyTyped/DefinitelyTyped/node/node-0.12.d.ts#03f3ca4333161dea8c5fa0ba47d55b02da92d40d  2016-09-06T15:26:30.000Z
0.11.13+20160906152630 0.11.13                      github:DefinitelyTyped/DefinitelyTyped/node/node-0.11.d.ts#03f3ca4333161dea8c5fa0ba47d55b02da92d40d  2016-09-06T15:26:30.000Z
0.10.1+20160906152630  0.10.1                       github:DefinitelyTyped/DefinitelyTyped/node/node-0.10.d.ts#03f3ca4333161dea8c5fa0ba47d55b02da92d40d  2016-09-06T15:26:30.000Z
0.8.8+20160906152630   0.8.8                        github:DefinitelyTyped/DefinitelyTyped/node/node-0.8.8.d.ts#03f3ca4333161dea8c5fa0ba47d55b02da92d40d 2016-09-06T15:26:30.000Z

猜你在找的Angularjs相关文章