我想实现bingmap在角6使用“角图” NPM包,我已经请参考也被称为 问题陈述:在node_modules没有创建“bingmaps”文件夹
app.module.ts
/// <reference path="node_modules/bingmaps/types/MicrosoftMaps/Microsoft.Maps.All.d.ts" />
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { MapModule, MapAPILoader, BingMapAPILoaderConfig, BingMapAPILoader, WindowRef, DocumentRef, MapServiceFactory, BingMapServiceFactory } from "angular-maps";
import { AppComponent } from './app.component';
Run Code Online (Sandbox Code Playgroud)
错误:
./node_modules/angular-maps/fesm5/angular-maps.js 中的错误模块未找到:错误:无法解析 'D:\bingmap\bingmap\node_modules\angular-maps\fesm5' 中的 'bingmaps' i ?wdm ?: 编译失败。src/app/app.module.ts(1,23) 中的错误:错误 TS6053:文件 'D:/bingmap/bingmap/src/app/node_modules/bingmaps/types/MicrosoftMaps/Microsoft.Maps.All.d.ts ' 未找到。
也安装了 npm install --save @types/bingmaps