Skip to content

Commit

Permalink
Use Webview to manage cluster settings
Browse files Browse the repository at this point in the history
Fixes jlandersen#88

Signed-off-by: azerr <[email protected]>
  • Loading branch information
angelozerr committed Jul 1, 2021
1 parent 632c49f commit 33d1b63
Show file tree
Hide file tree
Showing 10 changed files with 5,413 additions and 342 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.DS_Store
out/
dist/
pages/

.vscode-test/

Expand Down
69 changes: 40 additions & 29 deletions build/node-extension.webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,50 @@
'use strict';

const path = require('path');
const copyWebpackPlugin = require('copy-webpack-plugin');

/**@type {import('webpack').Configuration}*/
const config = {
target: 'node', // vscode extensions run in a Node.js-context πŸ“– -> https://webpack.js.org/configuration/node/
mode: 'none', // this leaves the source code as close as possible to the original (when packaging we set this to 'production')
target: 'node', // vscode extensions run in a Node.js-context πŸ“– -> https://webpack.js.org/configuration/node/
mode: 'none', // this leaves the source code as close as possible to the original (when packaging we set this to 'production')

entry: './src/extension.ts', // the entry point of this extension, πŸ“– -> https://webpack.js.org/configuration/entry-context/
output: {
// the bundle is stored in the 'dist' folder (check package.json), πŸ“– -> https://webpack.js.org/configuration/output/
path: path.resolve(__dirname, '..', 'dist'),
filename: 'extension.js',
libraryTarget: 'commonjs2'
},
devtool: 'nosources-source-map',
externals: {
vscode: 'commonjs vscode' // the vscode-module is created on-the-fly and must be excluded. Add other modules that cannot be webpack'ed, πŸ“– -> https://webpack.js.org/configuration/externals/
},
resolve: {
// support reading TypeScript and JavaScript files, πŸ“– -> https://github.com/TypeStrong/ts-loader
extensions: ['.ts', '.js']
},
module: {
rules: [
{
test: /\.ts$/,
exclude: /node_modules/,
use: [
{
loader: 'ts-loader'
}
entry: './src/extension.ts', // the entry point of this extension, πŸ“– -> https://webpack.js.org/configuration/entry-context/
output: {
// the bundle is stored in the 'dist' folder (check package.json), πŸ“– -> https://webpack.js.org/configuration/output/
path: path.resolve(__dirname, '..', 'dist'),
filename: 'extension.js',
libraryTarget: 'commonjs2'
},
devtool: 'nosources-source-map',
externals: {
vscode: 'commonjs vscode' // the vscode-module is created on-the-fly and must be excluded. Add other modules that cannot be webpack'ed, πŸ“– -> https://webpack.js.org/configuration/externals/
},
resolve: {
// support reading TypeScript and JavaScript files, πŸ“– -> https://github.com/TypeStrong/ts-loader
extensions: ['.ts', '.js'],
alias: {
'handlebars': 'handlebars/dist/handlebars.js'
}
},
module: {
rules: [
{
test: /\.ts$/,
exclude: /node_modules/,
use: [
{
loader: 'ts-loader'
}
]
}
]
}
},
plugins: [
new copyWebpackPlugin({
patterns: [
{ from: 'node_modules/@redhat-developer/vscode-wizard/pages', to: '../pages' }
]
})
]
}
};
module.exports = config;
module.exports = config;
Loading

0 comments on commit 33d1b63

Please sign in to comment.