Skip to content

Commit ffe5da3

Browse files
committed
bundle node_modules and (shallow) exclude them from the extension microsoft#56081
1 parent 34f629f commit ffe5da3

5 files changed

Lines changed: 13 additions & 14 deletions

File tree

extensions/emmet/.vscodeignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,7 @@ test/**
22
src/**
33
out/**
44
tsconfig.json
5+
node_modules/@emmetio/css-parser/**
6+
node_modules/@emmetio/html-matcher/**
7+
node_modules/@emmetio/math-expression/**
8+
node_modules/image-size/**

extensions/emmet/extension.webpack.config.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@ module.exports = withDefaults({
1515
extension: './src/extension.ts',
1616
},
1717
externals: {
18-
'@emmetio/css-parser': 'commonjs @emmetio/css-parser',
19-
'@emmetio/html-matcher': 'commonjs @emmetio/html-matcher',
20-
'@emmetio/math-expression': 'commonjs @emmetio/math-expression',
21-
'image-size': 'commonjs image-size',
2218
'vscode-emmet-helper': 'commonjs vscode-emmet-helper',
2319
},
2420
});

extensions/git/.vscodeignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,8 @@ test/**
33
out/**
44
tsconfig.json
55
build/**
6+
node_modules/byline/**
7+
node_modules/file-type/**
8+
node_modules/iconv-lite/**
9+
node_modules/jschardet/**
10+
node_modules/which/**

extensions/git/extension.webpack.config.js

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,5 @@ module.exports = withDefaults({
2525
{ from: './out/*.sh', to: '[name].sh' },
2626
{ from: './out/nls.*.json', to: '[name].json' }
2727
])
28-
],
29-
externals: {
30-
"byline": 'commonjs byline',
31-
"file-type": 'commonjs file-type',
32-
"iconv-lite": 'commonjs iconv-lite',
33-
"jschardet": 'commonjs jschardet',
34-
"vscode-extension-telemetry": 'commonjs vscode-extension-telemetry',
35-
"vscode-nls": 'commonjs vscode-nls',
36-
"which": 'commonjs which',
37-
},
28+
]
3829
});

extensions/shared.webpack.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ module.exports = function withDefaults(/**@type WebpackConfig*/extConfig) {
4646
},
4747
externals: {
4848
'vscode': 'commonjs vscode', // ignored because it doesn't exist
49+
50+
"vscode-extension-telemetry": 'commonjs vscode-extension-telemetry', // commonly used
51+
"vscode-nls": 'commonjs vscode-nls',
4952
},
5053
output: {
5154
// all output goes into `dist`.

0 commit comments

Comments
 (0)