Pulse7
8/19/2017 - 8:37 AM

Setup and Configuration

Setup and Configuration

module.exports={
    entry:"./main",
    output:{ filename:"app.js"},
    module:{
        loaders:[
            {
                test: /.ts$/,
                loader: "ts-loader"
            }
        ]
    },
    resolve:{
        extensions:[".ts",".js"]
    }
}
{
    "compilerOptions": {
        "target": "es5",
        "module": "commonjs",
        "sourceMap": true
    }
}
npm install rxjs --save
npm install webpack webpack-dev-server typescript typings ts-loader --save-dev
node_modules\.bin\typings install dt~es6-shim --global --save
<!DOCTYPE html>
<html lang="en">
<head>
    <title>Document</title>
</head>
<body>
    <div>Hello</div>
<script src="app.js"></script>
</body>
</html>