0
我想使用的Highcharts模塊加速Highcharts打字稿增強模塊
的定義爲存在打字稿定義:
// Type definitions for Highcharts 4.2.6 (boost module)
// Project: http://www.highcharts.com/
// Definitions by: Daniel Martin <http://github.com/inad9300>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
import { Static } from "highcharts";
declare function HighchartsBoost(H: Static): Static;
export = HighchartsBoost;
export as namespace HighchartsBoost;
當我嘗試導入它們下面的任一:
import { HighchartsBoost } from "highcharts/modules/boost";
import * as HighchartsBoost from "highcharts/modules/boost";
我得到錯誤:模塊解析爲非模塊實體,無法使用此構造導入。
任何想法?
這不會給打字稿定義爲功能HighchartsBoost – austinrulezd00d
這並不提供答案的問題。要批評或要求作者澄清,請在其帖子下方留言。 - [來自評論](/ review/low-quality-posts/16840904) –
對不起,我包含了我測試導入的模塊,而不是''highcharts/modules/boost'''。剛剛更新了我的答案,這種方式工作。 – Stephan