We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$ npm i @types/node -D
I had run tsc and it generates js files, then I create a index.html, the browser reports an error above:
tsc
js
index.html
... <script src="../dist/index.js"></script>
浏览器无法解析module,tsc只能编译成commonjs,umd等格式,所以必须用webpack,rollup之类的工具进行编译 https://stackoverflow.com/a/43473448/7909869
module
commonjs
umd
The text was updated successfully, but these errors were encountered:
No branches or pull requests
console is not defined
Uncaught ReferenceError: exports is not defined
I had run
tsc
and it generatesjs
files, then I create aindex.html
, the browser reports an error above:浏览器无法解析
module
,tsc
只能编译成commonjs
,umd
等格式,所以必须用webpack,rollup之类的工具进行编译 https://stackoverflow.com/a/43473448/7909869The text was updated successfully, but these errors were encountered: