webpack: generate sourcemap

This is necessary for debugging.

Updates golang/vscode-go#308

Change-Id: I4eb929b321cc30b72bff7f7fb1716db0f04be765
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/241599
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
diff --git a/webpack.config.js b/webpack.config.js
index 80c8737..65d2b3f 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -4,7 +4,7 @@
 
 const path = require('path');
 
-/**@type {import('webpack').WebpackOptions}*/
+/**@type {import('webpack').Configuration}*/
 const config = {
 	target: 'node',
 	entry: {
@@ -16,9 +16,10 @@
 		path: path.resolve(__dirname, 'dist'),
 		filename: '[name].js',
 		libraryTarget: 'commonjs2',
-		devtoolModuleFilenameTemplate: '../[resource-path]'
+		devtoolModuleFilenameTemplate: '../[resource-path]',
+		sourceMapFilename: '[name].js.map'
 	},
-	devtool: 'none',
+	devtool: 'source-map',
 	externals: {
 		// the vscode-module is created on-the-fly and must be excluded.
 		vscode: 'commonjs vscode'