-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
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
Debugging possible with Visual Studio? #16
Comments
Thanks! I suspect this is because the bundles are not being written to the file system, they are just held in memory. You could try adding the WriteFilePlugin? Let me know if that works, and I can add it to the readme, otherwise I can change the handler to write the files out to disk as well. |
Well, I don't know if I used it well, but it doesn't work better. var path = require('path');
var webpack = require('webpack');
var WebpackNotifierPlugin = require('webpack-notifier');
var WriteFileWebpackPlugin = require('write-file-webpack-plugin');
module.exports = function (env) {
return {
mode: env,
context: path.join(__dirname, 'Scripts'),
entry: ['react-hot-loader/patch', 'webpack-aspnet-middleware/client', './index'],
devtool: 'source-map',
resolve: {
extensions: ['.ts', '.tsx', '.js', '.jsx']
},
externals: {
"oimo": "OIMO",
"cannon": "CANNON",
"earcut": true
},
output: {
publicPath: '/webpack/',
path: path.join(__dirname, 'wwwroot', 'webpack'),
filename: '[name].bundle.js'
},
plugins: [
new WebpackNotifierPlugin(),
new webpack.HotModuleReplacementPlugin(),
new WriteFileWebpackPlugin({ test: /\.tsx?$/})
],
module: {
rules: [
{ test: /\.tsx?$/, use: ['react-hot-loader/webpack', 'awesome-typescript-loader'], exclude: /node_modules/ },
{ test: /\.css$/, use: ['style-loader', 'css-loader'] }
]
}
};
} Strange this I discovered: if I put a breakpoint in Chrome and make it hit, then will it also hit in Visual Studio and then I'll be able to put other breakpoints in VS and debug there as well... Thank you for the help! The web is a jungle and I don't go there very often on the client side! :) |
What if you try it without any arguments |
Still no effect. |
Hello,
First, great project, it's a life saver ! :)
I was wondering if we could still benefit of debugging TypeScript code within Visual Studio, apparently it's no longer the case with your sample and the app I quickly cook.
I'm not webpack expert, but the .js.map are generated fine, but apparently VS can't relate .ts files with what's being executed.
Thanks
The text was updated successfully, but these errors were encountered: