Update webpack, css/file & style loaders (#179008)

This commit is contained in:
Martin Aeschlimann 2023-04-03 16:10:40 +02:00 committed by GitHub
parent 1ee72c4854
commit 59608d3aee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 511 additions and 1641 deletions

View file

@ -12,7 +12,6 @@
"@types/cssnano": "^4.0.0",
"@types/debounce": "^1.0.0",
"@types/debug": "4.1.5",
"@types/eslint": "4.16.1",
"@types/fancy-log": "^1.3.0",
"@types/fs-extra": "^9.0.12",
"@types/glob": "^7.1.1",
@ -38,7 +37,6 @@
"@types/through2": "^2.0.36",
"@types/tmp": "^0.2.1",
"@types/underscore": "^1.8.9",
"@types/webpack": "^4.41.25",
"@types/xml2js": "0.0.33",
"@vscode/iconv-lite-umd": "0.7.0",
"@vscode/vsce": "^2.16.0",

View file

@ -323,19 +323,6 @@
resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.5.tgz#b14efa8852b7768d898906613c23f688713e02cd"
integrity sha512-Q1y515GcOdTHgagaVFhHnIFQ38ygs/kmxdNpvpou+raI9UO3YZcHDngBSYKQklcKlvA7iuQlmIKbzvmxcOE9CQ==
"@types/eslint@4.16.1":
version "4.16.1"
resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-4.16.1.tgz#19730c9fcb66b6e44742d12b27a603fabfeb2f49"
integrity sha512-lRUXQAULl5geixTiP2K0iYvMUbCkEnuOwvLGjwff12I4ECxoW5QaWML5UUOZ1CvpQLILkddBdMPMZz4ByQizsg==
dependencies:
"@types/estree" "*"
"@types/json-schema" "*"
"@types/estree@*":
version "0.0.41"
resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.41.tgz#fd90754150b57432b72bf560530500597ff04421"
integrity sha512-rIAmXyJlqw4KEBO7+u9gxZZSQHaCNnIzYrnNmYVpgfJhxTqO0brCX0SYpqUTkVI5mwwUwzmtspLBGBKroMeynA==
"@types/events@*":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@types/events/-/events-1.2.0.tgz#81a6731ce4df43619e5c8c945383b3e62a89ea86"
@ -449,11 +436,6 @@
resolved "https://registry.yarnpkg.com/@types/js-beautify/-/js-beautify-1.8.0.tgz#0369d3d0e1f35a6aec07cb4da2ee2bcda111367c"
integrity sha512-/siF86XrwDKLuHe8l7h6NhrAWgLdgqbxmjZv9NvGWmgYRZoTipkjKiWb0SQHy/jcR+ee0GvbG6uGd+LEBMGNvA==
"@types/json-schema@*":
version "7.0.4"
resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.4.tgz#38fd73ddfd9b55abb1e1b2ed578cb55bd7b7d339"
integrity sha512-8+KAKzEvSUdeo+kmqnKrqgeE+LcA0tjYWFY7RPProVYwnqDjukzO+3b6dLD56rYX5TdWejnEOLJYOIeh4CXKuA==
"@types/keyv@*":
version "3.1.1"
resolved "https://registry.yarnpkg.com/@types/keyv/-/keyv-3.1.1.tgz#e45a45324fca9dab716ab1230ee249c9fb52cfa7"
@ -545,16 +527,6 @@
"@types/glob" "*"
"@types/node" "*"
"@types/source-list-map@*":
version "0.1.2"
resolved "https://registry.yarnpkg.com/@types/source-list-map/-/source-list-map-0.1.2.tgz#0078836063ffaf17412349bba364087e0ac02ec9"
integrity sha512-K5K+yml8LTo9bWJI/rECfIPrGgxdpeNbj+d53lwN4QjW1MCwlkhUms+gtdzigTeUyBr09+u8BwOIY3MXvHdcsA==
"@types/tapable@^1":
version "1.0.8"
resolved "https://registry.yarnpkg.com/@types/tapable/-/tapable-1.0.8.tgz#b94a4391c85666c7b73299fd3ad79d4faa435310"
integrity sha512-ipixuVrh2OdNmauvtT51o3d8z12p6LtFW9in7U79der/kwejjdNchQC5UMn5u/KxNoM7VHHOs/l8KS8uHxhODQ==
"@types/through2@^2.0.36":
version "2.0.36"
resolved "https://registry.yarnpkg.com/@types/through2/-/through2-2.0.36.tgz#35fda0db635827d44c0e08e2c94653e647574a00"
@ -586,13 +558,6 @@
dependencies:
"@types/node" "*"
"@types/uglify-js@*":
version "3.13.1"
resolved "https://registry.yarnpkg.com/@types/uglify-js/-/uglify-js-3.13.1.tgz#5e889e9e81e94245c75b6450600e1c5ea2878aea"
integrity sha512-O3MmRAk6ZuAKa9CHgg0Pr0+lUOqoMLpc9AS4R8ano2auvsg7IE8syF3Xh/NPr26TWklxYcqoEEFdzLLs1fV9PQ==
dependencies:
source-map "^0.6.1"
"@types/underscore@^1.8.9":
version "1.8.9"
resolved "https://registry.yarnpkg.com/@types/underscore/-/underscore-1.8.9.tgz#fef41f800cd23db1b4f262ddefe49cd952d82323"
@ -628,27 +593,6 @@
dependencies:
"@types/node" "*"
"@types/webpack-sources@*":
version "2.1.1"
resolved "https://registry.yarnpkg.com/@types/webpack-sources/-/webpack-sources-2.1.1.tgz#6af17e3a3ded71eec2b98008d7c12f498a0a4506"
integrity sha512-MjM1R6iuw8XaVbtkCBz0N349cyqBjJHCbQiOeppe3VBeFvxqs74RKHAVt9LkxTnUWc7YLZOEsUfPUnmK6SBPKQ==
dependencies:
"@types/node" "*"
"@types/source-list-map" "*"
source-map "^0.7.3"
"@types/webpack@^4.41.25":
version "4.41.30"
resolved "https://registry.yarnpkg.com/@types/webpack/-/webpack-4.41.30.tgz#fd3db6d0d41e145a8eeeafcd3c4a7ccde9068ddc"
integrity sha512-GUHyY+pfuQ6haAfzu4S14F+R5iGRwN6b2FRNJY7U0NilmFAqbsOfK6j1HwuLBAqwRIT+pVdNDJGJ6e8rpp0KHA==
dependencies:
"@types/node" "*"
"@types/tapable" "^1"
"@types/uglify-js" "*"
"@types/webpack-sources" "*"
anymatch "^3.0.0"
source-map "^0.6.0"
"@types/xml2js@0.0.33":
version "0.0.33"
resolved "https://registry.yarnpkg.com/@types/xml2js/-/xml2js-0.0.33.tgz#20c5dd6460245284d64a55690015b95e409fb7de"
@ -748,7 +692,7 @@ ansi-wrap@0.1.0, ansi-wrap@^0.1.0:
resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf"
integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768=
anymatch@^3.0.0, anymatch@^3.1.1, anymatch@~3.1.1:
anymatch@^3.1.1, anymatch@~3.1.1:
version "3.1.2"
resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.2.tgz#c0557c096af32f106198f4f4e2a383537e378716"
integrity sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==
@ -2881,16 +2825,11 @@ simple-get@^4.0.0:
once "^1.3.1"
simple-concat "^1.0.0"
source-map@0.6.1, source-map@^0.6.0, source-map@^0.6.1:
source-map@0.6.1, source-map@^0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
source-map@^0.7.3:
version "0.7.3"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383"
integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==
sprintf-js@^1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.1.2.tgz#da1765262bf8c0f571749f2ad6c26300207ae673"

View file

@ -22,8 +22,7 @@ const tsLoaderOptions = {
onlyCompileBundledFiles: true,
};
function withNodeDefaults(/**@type WebpackConfig*/extConfig) {
/** @type WebpackConfig */
function withNodeDefaults(/**@type WebpackConfig & { context: string }*/extConfig) {
const defaultConfig = {
mode: 'none', // this leaves the source code as close as possible to the original (when packaging we set this to 'production')
target: 'node', // extensions run in a node context
@ -105,7 +104,7 @@ function nodePlugins(context) {
* }} AdditionalBrowserConfig
*/
function withBrowserDefaults(/**@type WebpackConfig*/extConfig, /** @type AdditionalBrowserConfig */ additionalOptions = {}) {
function withBrowserDefaults(/**@type WebpackConfig & { context: string }*/extConfig, /** @type AdditionalBrowserConfig */ additionalOptions = {}) {
/** @type WebpackConfig */
const defaultConfig = {
mode: 'none', // this leaves the source code as close as possible to the original (when packaging we set this to 'production')

View file

@ -42,7 +42,6 @@ module.exports = [withBrowserDefaults({
{
from: '../node_modules/typescript/lib/*.d.ts',
to: 'typescript/',
flatten: true
},
{
from: '../node_modules/typescript/lib/typesMap.json',
@ -50,9 +49,14 @@ module.exports = [withBrowserDefaults({
},
...languages.map(lang => ({
from: `../node_modules/typescript/lib/${lang}/**/*`,
to: 'typescript/',
transformPath: (targetPath) => {
return targetPath.replace(/\.\.[\/\\]node_modules[\/\\]typescript[\/\\]lib/, '');
to: (pathData) => {
const normalizedFileName = pathData.absoluteFilename.replace(/[\\/]/g, '/');
const match = normalizedFileName.match(/typescript\/lib\/(.*)/);
if (match) {
return `typescript/${match[1]}`;
}
console.log(`Did not find typescript/lib in ${normalizedFileName}`);
return 'typescript/';
}
}))
],

View file

@ -103,7 +103,6 @@
"@swc/cli": "0.1.57",
"@swc/core": "1.3.32",
"@types/cookie": "^0.3.3",
"@types/copy-webpack-plugin": "^6.0.3",
"@types/cssnano": "^4.0.0",
"@types/debug": "4.1.5",
"@types/graceful-fs": "4.1.2",
@ -118,7 +117,7 @@
"@types/sinon-test": "^2.4.2",
"@types/trusted-types": "^1.0.6",
"@types/vscode-notebook-renderer": "^1.72.0",
"@types/webpack": "^4.41.25",
"@types/webpack": "^5.28.1",
"@types/wicg-file-system-access": "^2020.9.5",
"@types/windows-foreground-love": "^0.3.0",
"@types/windows-mutex": "^0.4.0",
@ -137,9 +136,9 @@
"asar": "^3.0.3",
"chromium-pickle-js": "^0.2.0",
"cookie": "^0.4.0",
"copy-webpack-plugin": "^6.0.3",
"copy-webpack-plugin": "^11.0.0",
"cson-parser": "^1.3.3",
"css-loader": "^3.6.0",
"css-loader": "^6.7.3",
"cssnano": "^4.1.11",
"debounce": "^1.0.0",
"deemon": "^1.8.0",
@ -151,7 +150,7 @@
"event-stream": "3.3.4",
"fancy-log": "^1.3.3",
"fast-plist": "0.1.3",
"file-loader": "^5.1.0",
"file-loader": "^6.2.0",
"glob": "^5.0.13",
"gulp": "^4.0.0",
"gulp-atom-electron": "^1.33.0",
@ -206,8 +205,8 @@
"sinon-test": "^3.1.3",
"source-map": "0.6.1",
"source-map-support": "^0.3.2",
"style-loader": "^1.3.0",
"ts-loader": "^9.2.7",
"style-loader": "^3.3.2",
"ts-loader": "^9.4.2",
"ts-node": "^10.9.1",
"tsec": "0.1.4",
"typescript": "^5.1.0-dev.20230328",
@ -217,9 +216,9 @@
"vinyl": "^2.0.0",
"vinyl-fs": "^3.0.0",
"vscode-nls-dev": "^3.3.1",
"webpack": "^5.42.0",
"webpack-cli": "^4.7.2",
"webpack-stream": "^6.1.2",
"webpack": "^5.77.0",
"webpack-cli": "^5.0.1",
"webpack-stream": "^7.0.0",
"xml2js": "^0.4.17",
"yaserver": "^0.2.0"
},

2049
yarn.lock

File diff suppressed because it is too large Load diff