Angular6, ошибка старших диаграмм "ОШИБКА в node_modules / highcharts / highcharts.d.ts (128972,17) 'PlotNetworkDataLabelsFormatterCallbackFunction'." - PullRequest
0 голосов
/ 08 апреля 2019

Я пытаюсь настроить highcharts с Angular6, выполнив следующие действия:

Step 1 : npm install highcharts-angular --save
Step 2 : Add HighchartsChartModule in app.module.ts under imports
imports: [
HighchartsChartModule
]
Add import statement'import { HighchartsChartModule } from 'highcharts-angular';
Step 3 : npm install highcharts --save

После этого при сборке приложения выдается сообщение об ошибке ниже


ERROR in node_modules/highcharts/highcharts.d.ts(128972,17): error TS2304: Cannot find name 'PlotNetworkDataLabelsFormatterCallbackFunction'.
node_modules/highcharts/highcharts.d.ts(128982,21): error TS2304: Cannot find name 'PlotNetworkDataLabelsFormatterCallbackFunction'.
node_modules/highcharts/highcharts.d.ts(128987,19): error TS2304: Cannot find name 'PlotNetworkDataLabelsTextPath'.
node_modules/highcharts/highcharts.d.ts(128992,15): error TS2304: Cannot find name 'PlotNetworkDataLabelsTextPath'.
node_modules/highcharts/highcharts.d.ts(136653,17): error TS2304: Cannot find name 'PlotPackedBubbleDataLabelsFormatterCallbackFunction'.
node_modules/highcharts/highcharts.d.ts(136658,15): error TS2304: Cannot find name 'PlotPackedBubbleDataLabelsTextPath'.
node_modules/highcharts/highcharts.d.ts(237720,14): error TS2304: Cannot find name 'SeriesOrganizationNodesLayoutValues'.


мой package.json выглядиткак показано ниже

Package.json 

 "dependencies": {
        "@agm/core": "^1.0.0-beta.3",
        "@angular/animations": "6.1.0",
        "@angular/cdk": "^6.4.1",
        "@angular/common": "6.1.0",
        "@angular/compiler": "6.1.0",
        "@angular/core": "6.1.0",
        "@angular/flex-layout": "^6.0.0-beta.18",
        "@angular/forms": "6.1.0",
        "@angular/http": "6.1.0",
        "@angular/material": "^6.4.1",
        "@angular/material-moment-adapter": "^6.4.1",
        "@angular/platform-browser": "6.1.0",
        "@angular/platform-browser-dynamic": "6.1.0",
        "@angular/router": "6.1.0",
        "@types/googlemaps": "^3.30.11",
        "angular-highcharts-chart": "^1.0.2",
        "core-js": "^2.5.7",
        "file-input-accessor": "^2.0.0",
        "hammerjs": "^2.0.8",
        "highcharts": "^7.1.0",
        "highcharts-angular": "^2.4.0",
        "moment": "^2.22.2",
        "moment-business-days": "^1.0.6",
        "ngx-cookie": "^4.1.2",
        "ngx-storage": "^0.5.0",
        "ngx-webstorage": "^2.0.1",
        "rxjs": "^6.4.0",
        "rxjs-compat": "^6.2.2",
        "rxjs-tslint": "^0.1.5",
        "zone.js": "^0.8.26"
    },

Я действительно застрял с этой настройкой!Любая помощь высоко ценится !!Заранее спасибо !!

Ответы [ 2 ]

0 голосов
/ 08 апреля 2019

Установка highcharts версии 7.0.3 сработала у меня.

npm install highcharts@7.0.3

Спасибо !!

0 голосов
/ 08 апреля 2019

Измените версию с высокой диаграммой на 7.0.3

npm install highcharts@7.0.3

все работает нормально.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...