Xiaobai uses ts to write code for the first time. Ask the great gods to help answer ~
html introduces jquery
<script src="node_modules/handlebars/dist/handlebars.js"></script>
<script src="D:/exercise/TS/TODO/node_modules/jquery/dist/jquery.js"></script>
<script>var exports = {};</script>
<script src="js/todo.js"></script>
ts Code
import jQuery = require("jQuery");
import Handlebars = require("handlebars");
jQuery(function ($) {
console.log("1111111");
...
})
compiled js code
"use strict";
exports.__esModule = true;
var jQuery = require("jQuery");
var Handlebars = require("handlebars");
jQuery(function ($) {
console.log("1111111");
...
})
error report: