【发布时间】:2018-05-15 15:32:12
【问题描述】:
在我使用电子锻造创建的电子角度应用程序中,我正在尝试导入 jquery。
我做了以下步骤:
-
已安装 jquery
yarn add jquery --save -
已安装的类型
yarn add @types/jquery --save -
导入到 app.module
import * as $ from 'jquery';
当我启动应用程序时,我得到了
index.js:21 Uncaught ReferenceError: $ is not defined
at index.js:21
【问题讨论】: