diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index 8fa2afe0..0f5dc883 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -23,6 +23,16 @@ jobs: with: version: 9 + - name: Install + shell: bash + run: | + npm ci + + - name: Versions Report + shell: bash + run: | + npm run report:versions + - name: Execute verification shell: bash run: | diff --git a/package.json b/package.json index 0a615fa4..45de13f3 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,9 @@ }, "volta": { "node": "22.12.0", - "npm": "10.9.0" + "npm": "10.9.0", + "pnpm": "9.15.0", + "yarn": "4.5.3" }, "devDependencies": { "@codingame/esbuild-import-meta-url-plugin": "~1.0.2", @@ -50,7 +52,10 @@ "production:preview": "npm run production:preview --workspace packages/examples", "dev": "vite", "dev:debug": "vite --debug --force", - "report:versions": "echo Reporting versions: && echo tsc: && tsc --version && echo npm: && npm --version && echo node: && node --version && echo eslint: && eslint --version && echo vite: && vite --version && echo vitest: && vitest --version", + "report:versions:vite": "echo vite: && vite --version && echo vitest: && vitest --version", + "report:versions:node": "echo npm: && npm --version && echo node: && node --version && echo eslint: && eslint --version", + "report:versions:tools": "echo tsc: && tsc --version && echo eslint: && eslint --version && echo pnpm: && pnpm --version && echo yarn: && yarn --version", + "report:versions": "echo Reporting versions: && npm run report:versions:node && npm run report:versions:vite && npm run report:versions:tools", "build": "npm run build --workspaces", "build:client": "npm run build --workspace packages/client", "build:vscode-ws-jsonrpc": "npm run build --workspace packages/vscode-ws-jsonrpc", diff --git a/verify/angular/package.json b/verify/angular/package.json index 4414bd5d..bf1cdd88 100644 --- a/verify/angular/package.json +++ b/verify/angular/package.json @@ -46,5 +46,5 @@ "start:production": "npm run clean && ng serve --configuration production", "watch": "npm run clean && ng build --watch --configuration development", "reset:repo": "git clean -f -X -d" - }, + } } diff --git a/verify/angular/src/monaco-angular-wrapper/monaco-angular-wrapper.component.ts b/verify/angular/src/monaco-angular-wrapper/monaco-angular-wrapper.component.ts index 6ef3d69a..a4e6ae1f 100644 --- a/verify/angular/src/monaco-angular-wrapper/monaco-angular-wrapper.component.ts +++ b/verify/angular/src/monaco-angular-wrapper/monaco-angular-wrapper.component.ts @@ -74,11 +74,11 @@ export class MonacoAngularWrapperComponent implements OnDestroy { handleOnTextChanged() { const wrapperConfig = this.wrapperConfig(); const textModels = this.wrapper.getTextModels(); - if (textModels?.text !== undefined && wrapperConfig !== undefined) { + if (textModels?.modified !== undefined && wrapperConfig !== undefined) { const newSubscriptions: monaco.IDisposable[] = []; this.emitCodeChange(textModels, wrapperConfig); newSubscriptions.push( - textModels.text.onDidChangeContent(() => { + textModels.modified.onDidChangeContent(() => { this.emitCodeChange(textModels, wrapperConfig); }) ); @@ -87,7 +87,7 @@ export class MonacoAngularWrapperComponent implements OnDestroy { emitCodeChange(textModels: TextModels, wrapperConfig: WrapperConfig) { const onTextChanged = (textChanges: TextChanges) => { - this.onTextChanged.emit(textChanges.text); + this.onTextChanged.emit(textChanges.modified); }; didModelContentChange(textModels, wrapperConfig.editorAppConfig?.codeResources, onTextChanged); } diff --git a/verify/buildAll.ps1 b/verify/buildAll.ps1 index 2abb9906..71e66147 100644 --- a/verify/buildAll.ps1 +++ b/verify/buildAll.ps1 @@ -5,6 +5,4 @@ Set-Location $MyPath/webpack; npm run verify:ci Set-Location $MyPath/angular; npm run verify:ci Set-Location $MyPath/next; npm run verify:ci Set-Location $MyPath/pnpm; pnpm run verify:ci - -# yarn example is instable because we can't refence local file based dependencies Set-Location $MyPath/yarn; yarn run verify:ci diff --git a/verify/buildAll.sh b/verify/buildAll.sh index 076ac3ec..e24b3d7e 100644 --- a/verify/buildAll.sh +++ b/verify/buildAll.sh @@ -5,6 +5,4 @@ cd $MyPath/webpack; npm run verify:ci cd $MyPath/angular; npm run verify:ci cd $MyPath/next; npm run verify:ci cd $MyPath/pnpm; pnpm run verify:ci - -# yarn example is instable because we can't refence local file based dependencies cd $MyPath/yarn; yarn run verify:ci diff --git a/verify/next/next.config.mjs b/verify/next/next.config.mjs new file mode 100644 index 00000000..34caed3c --- /dev/null +++ b/verify/next/next.config.mjs @@ -0,0 +1,18 @@ +/** + * @type {import('next').NextConfig} + */ +export default { + typescript: { + tsconfigPath: './tsconfig.json', + }, + output: 'standalone', + webpack: (config, { isServer }) => { + if (!isServer) { + config.resolve.fallback.fs = false; + config.resolve.fallback.module = false; + config.resolve.fallback.vm = false; + } + + return config; + }, +}; diff --git a/verify/webpack/webpack.config.js b/verify/webpack/webpack.config.js index b4e60bf1..8f35e760 100644 --- a/verify/webpack/webpack.config.js +++ b/verify/webpack/webpack.config.js @@ -40,6 +40,7 @@ const config = { extensions: ['.ts', '.js', '.json', '.ttf'], fallback: { fs: false, + module: false, vm: false } }, diff --git a/verify/yarn/package.json b/verify/yarn/package.json index aa6ee2b6..836b27f8 100644 --- a/verify/yarn/package.json +++ b/verify/yarn/package.json @@ -34,8 +34,9 @@ "vite": "~6.0.3" }, "scripts": { - "verify": "yarn install && yarn run build && yarn run start", - "verify:ci": "yarn install && yarn run build", + "version:print": "yarn --version", + "verify": "yarn run version:print && yarn install && yarn run build && yarn run start", + "verify:ci": "yarn run version:print && yarn install && yarn run build", "clean": "shx rm -fr dist", "build:msg": "echo Building yarn/vite example:", "build": "yarn run build:msg && yarn run clean && vite build", diff --git a/verify/yarn/yarn.lock b/verify/yarn/yarn.lock index e69de29b..18991e2c 100644 --- a/verify/yarn/yarn.lock +++ b/verify/yarn/yarn.lock @@ -0,0 +1,12 @@ +# This file is generated by running "yarn install" inside your project. +# Manual changes might be lost - proceed with caution! + +__metadata: + version: 8 + cacheKey: 10c0 + +"mlc-verify-yarn@workspace:.": + version: 0.0.0-use.local + resolution: "mlc-verify-yarn@workspace:." + languageName: unknown + linkType: soft