Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

编译时找不到类型定义报错 #68

Open
ygwoo opened this issue Apr 9, 2020 · 0 comments
Open

编译时找不到类型定义报错 #68

ygwoo opened this issue Apr 9, 2020 · 0 comments

Comments

@ygwoo
Copy link

ygwoo commented Apr 9, 2020

使用ngx-amap版本为"ngx-amap": "^3.0.5",
我在项目devDependencies中安装了类型依赖
"@types/amap-js-api": "^1.4.7",
"@types/amap-js-api-autocomplete": "^1.4.0",
"@types/amap-js-api-city-search": "^1.4.0",
"@types/amap-js-api-geocoder": "^1.4.0",
"@types/amap-js-api-geolocation": "^1.4.0",

angualr环境为:
Angular CLI: 8.3.21
Node: 13.12.0
OS: darwin x64
Angular: 8.2.14
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router

Package Version

@angular-devkit/architect 0.803.21
@angular-devkit/build-angular 0.803.21
@angular-devkit/build-optimizer 0.803.21
@angular-devkit/build-webpack 0.803.21
@angular-devkit/core 8.3.21
@angular-devkit/schematics 8.3.21
@angular/cdk 8.2.3
@angular/cli 8.3.21
@ngtools/webpack 8.3.21
@schematics/angular 8.3.21
@schematics/update 0.803.21
rxjs 6.5.3
typescript 3.5.3
webpack 4.39.2
报错代码:
image
加载高德AMap.Geolocation插件时编译报错,程序能正常运行,是否是 "@types/amap-js-api": "^1.4.7",缺少相关类型定义造成的?
报错截图:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant