我正在尝试使用以下行:
import Clipboard = require('clipboard');
我收到以下错误:
[default] c:\xampp\htdocs\isitperfect\node_modules\angular2-clipboard\src\clipboard.directive.ts:2:0 Import assignment cannot be used when targeting ECMAScript 2015 modules. Consider using 'import * as ns from "mod"','import {a} from "mod"','import d from "mod"',or another module format instead.
import Clipboard = require('clipboard');
我试过了:
import * as Clipboard from 'clipboard';
和其他一些变化,但无法弄清楚如何解决它.
我正在使用typescript 2.0.0
有任何想法吗?