angular 无法使用 syncfusion
Cannot use syncfusion for angular
我正在尝试在 angular 中使用 syncfusion 以便使用 Geomaps。
(https://ej2.syncfusion.com/angular/documentation/maps/getting-started/)
当我尝试执行我的组件时,出现此错误:
**ERROR in The target entry-point "@syncfusion/ej2-angular-maps" has missing dependencies:
- @angular/core
- @angular/common**
我尝试执行 npm install,在我的项目中添加 angular 核心的确切路径,但它不起作用。
这是我的 package.json 文件
` {
"name": "prova",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "~10.0.14",
"@angular/common": "~10.0.14",
"@angular/compiler": "~10.0.14",
"@angular/core": "~10.0.14",
"@angular/forms": "~10.0.14",
"@angular/platform-browser": "~10.0.14",
"@angular/platform-browser-dynamic": "~10.0.14",
"@angular/router": "~10.0.14",
"rxjs": "~6.5.5",
"tslib": "^2.0.0",
"zone.js": "~0.10.3"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.1000.8",
"@angular/cli": "~10.0.8",
"@angular/compiler-cli": "~10.0.14",
"@types/node": "^12.11.1",
"@types/jasmine": "~3.5.0",
"@types/jasminewd2": "~2.0.3",
"codelyzer": "^6.0.0",
"jasmine-core": "~3.5.0",
"jasmine-spec-reporter": "~5.0.0",
"karma": "~5.0.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage-istanbul-reporter": "~3.0.2",
"karma-jasmine": "~3.3.0",
"karma-jasmine-html-reporter": "^1.5.0",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint": "~6.1.0",
"typescript": "~3.9.5"
}
}
`
这是我的 tsconfig 文件
{
"files": [],
"references": [
{
"path": "./tsconfig.app.json"
},
{
"path": "./tsconfig.spec.json"
}
],
}
感谢您联系 Syncfusion 支持。
我们无法重现报告的问题。我们怀疑您的 package.json 文件中提到的软件包已过时。我们已经更新了应用程序中必要的包,并创建了一个示例应用程序供您参考。可以从以下link.
下载
https://www.syncfusion.com/downloads/support/directtrac/general/ze/Maps-1025419634.zip
在上面的 angular 示例中,我们使用 GeoJSON 数据渲染了一张世界地图。
如果您需要任何进一步的帮助,请告诉我们。
此致,
萨巴里阿南德
我正在尝试在 angular 中使用 syncfusion 以便使用 Geomaps。 (https://ej2.syncfusion.com/angular/documentation/maps/getting-started/) 当我尝试执行我的组件时,出现此错误:
**ERROR in The target entry-point "@syncfusion/ej2-angular-maps" has missing dependencies:
- @angular/core
- @angular/common**
我尝试执行 npm install,在我的项目中添加 angular 核心的确切路径,但它不起作用。
这是我的 package.json 文件
` {
"name": "prova",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "~10.0.14",
"@angular/common": "~10.0.14",
"@angular/compiler": "~10.0.14",
"@angular/core": "~10.0.14",
"@angular/forms": "~10.0.14",
"@angular/platform-browser": "~10.0.14",
"@angular/platform-browser-dynamic": "~10.0.14",
"@angular/router": "~10.0.14",
"rxjs": "~6.5.5",
"tslib": "^2.0.0",
"zone.js": "~0.10.3"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.1000.8",
"@angular/cli": "~10.0.8",
"@angular/compiler-cli": "~10.0.14",
"@types/node": "^12.11.1",
"@types/jasmine": "~3.5.0",
"@types/jasminewd2": "~2.0.3",
"codelyzer": "^6.0.0",
"jasmine-core": "~3.5.0",
"jasmine-spec-reporter": "~5.0.0",
"karma": "~5.0.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage-istanbul-reporter": "~3.0.2",
"karma-jasmine": "~3.3.0",
"karma-jasmine-html-reporter": "^1.5.0",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint": "~6.1.0",
"typescript": "~3.9.5"
}
}
`
这是我的 tsconfig 文件
{
"files": [],
"references": [
{
"path": "./tsconfig.app.json"
},
{
"path": "./tsconfig.spec.json"
}
],
}
感谢您联系 Syncfusion 支持。
我们无法重现报告的问题。我们怀疑您的 package.json 文件中提到的软件包已过时。我们已经更新了应用程序中必要的包,并创建了一个示例应用程序供您参考。可以从以下link.
下载https://www.syncfusion.com/downloads/support/directtrac/general/ze/Maps-1025419634.zip
在上面的 angular 示例中,我们使用 GeoJSON 数据渲染了一张世界地图。
如果您需要任何进一步的帮助,请告诉我们。
此致,
萨巴里阿南德