Commit Graph

135 Commits (main)

Author SHA1 Message Date
Matt Bierner e2e048ded8
Merge pull request #230345 from microsoft/dev/eslint-9
Eslint 9 migration
2024-10-07 09:15:12 -07:00
Benjamin Pasero dc265add0b
esm - drop need for manual concat (#230571) 2024-10-06 14:12:20 +02:00
Matt Bierner f22a1167e4 More fixes 2024-10-02 17:22:33 -07:00
Benjamin Pasero c7caef00ea
esm - make `optimize.ts` ESM only 2024-09-27 08:05:06 +02:00
Benjamin Pasero b544846460
esm - further cleanup build scripts 2024-09-27 08:04:56 +02:00
Benjamin Pasero eed219db5f
ESM: figure out the monaco-standalone ESM build story (fix #227192) (#227536) 2024-09-06 18:26:40 +02:00
Robo b5a6aa14a8
feat: switch to npm as default package manager (#226927)
* feat: move from yarn to npm

* chore: skip yarn.lock files

* fix: playwright download

* chore: fix compile and hygiene

* chore: bump vsce@2.17.0

Refs 8b49e9dfdf

* test: update results for bat and sh colorizer tests

* fix: add missing lock files for windows

* fix: switch to legacy-peer-deps

* chore: update markdown-it@14.1.0

Refs 737c95a129

esbuild step in extensions-ci-pr was previously using markdown-it
from root which had userland punycode and was able to compile successfully.

* ci: increase pr timeout for windows integration tests

* chore: fix product build

* build: ignore extension dev dependency for rcedit

* build: fix working directory inside container

* build: fix dependency generation

* npm: update dependencies

* ci: use global npmrc

* ci: update cache

* ci: setup global npmrc for private npm auth

* build: fix extension bundling

* chore: sync npm dependencies

* ci: debug env variables for container

* ci: fix win32 cli pipeline

* build: fix npmrc config usage for build/ and remote/ dirs

* fix: windows build

* fix: container builds

* fix: markdown-language-features tests and bundling

```
[03:58:22] Error: Command failed: /Users/demohan/.nvm/versions/node/v20.15.1/bin/node /Users/demohan/github/vscode/extensions/markdown-language-features/esbuild-notebook.js --outputRoot /Users/demohan/github/vscode/.build/extensions/markdown-language-features
✘ [ERROR] Could not resolve "punycode"

    extensions/markdown-language-features/node_modules/markdown-it/lib/index.js:14:27:
      14 │ var punycode     = require('punycode');
         ╵                            ~~~~~~~~~~

  The package "punycode" wasn't found on the file system but is built into node. Are you trying to bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
```

Adds userland package based on beed9aee2c

* fix: container builds for distro

* chore: update yarn occurrences

* fixup! chore: bump vsce@2.17.0

Uses the closest version to `main` branch that does not
include d3cc84cdec
while still having the fix 8b49e9dfdf

* chore: sync npm dependencies

* chore: sync npm dependencies

* chore: sync npm dependencies

* chore: throw error when yarn is used for installation

* chore: add review feedback

* chore: switch exec => run where needed

* chore: npm sync dependencies

* fix: markdown-language-features bundling

```
✘ [ERROR] Could not resolve "punycode"

    extensions/markdown-language-features/node_modules/markdown-it/lib/index.js:14:27:
      14 │ var punycode     = require('punycode');
         ╵                            ~~~~~~~~~~

  The package "punycode" wasn't found on the file system but is built into node. Are you trying to bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
```

Adds missing userland package based on markdown-it/markdown-it@beed9ae,
can be removed once we update markdown-it >= 14.1.0

* ci: rename no-yarn-lock-changes.yml

* chore: sync npm dependencies

* ci: restore no-yarn-lock-changes.yml

We can disable it in a separate PR to keep the required
checks happy and also need workflow edit perms.

* chore: sync npm dependencies

* ci: rebuild cache

* ci: fix no-package-lock-changes.yml

* chore: bump distro

* chore: rm yarn.lock files

* chore: rm yarn.lock files without dependencies

* chore: add vscode-selfhost-import-aid to postinstall dirs

* chore: bump distro
2024-09-06 22:18:02 +09:00
Alex Ross 977f832a30
Simple tree sitter based syntax highlighting for typescript (#225252)
* Simple tree sitter based syntax highlighting for typescript

Part of #210475

* Implement onceIf using filter

* Mix monaco

* Fix tests

* Switch back to classic

* PR feedback

* Fix bug causing test failure

* Update tree-sitter-wasm

* Fix monaco editor tree shaking

* Fix running monaco checks on Windows

* Use dummy tree sitter service in standalone

* PR feedback
2024-08-19 21:56:31 +02:00
Benjamin Pasero d65fd5ba2e
nls follow up debt work (#219265) 2024-07-01 11:44:19 +02:00
Benjamin Pasero 2014f1ddb2
nls - removal of loader plugin (#219098) 2024-06-28 15:45:52 +02:00
Benjamin Pasero f6f90e0163
Implement NLS without AMD loader (#214588) 2024-06-28 11:55:48 +02:00
Henning Dieterichs f26376f1f5 Removes unneeded monaco-editor-esm-bundle 2023-11-15 19:41:53 +01:00
Henning Dieterichs ebe458556d
Don't mangle fields for the monaco editor, FYI @jrieken (#177223) 2023-03-15 14:46:23 +01:00
Connor Peet 18f743d534
address pr comments 2022-10-05 12:56:07 -07:00
Benjamin Pasero 9db57e76e9
Build: bundle / concat entry points (#161161)
* perf - concatenate windows main files

* Revert "Revert "Use `esbuild` to bundle some CommonJS main files (#160957)" (#161118)"

This reverts commit 84c46b71a5.

* build - exclude server main files

* build - make concat a task that runs like the others

* some renames

* Avoid overwriting the nodejs closure require

* Revert "build - exclude server main files"

This reverts commit 736516624e.

Co-authored-by: Alex Dima <alexdima@microsoft.com>
2022-09-21 00:38:44 -07:00
Benjamin Pasero 84c46b71a5
Revert "Use `esbuild` to bundle some CommonJS main files (#160957)" (#161118)
This reverts commit 2179e52fb9.
2022-09-16 09:31:44 -07:00
Benjamin Pasero 2179e52fb9
Use `esbuild` to bundle some CommonJS main files (#160957)
* ensure node.js `require` is captured

* optimize `main.js` and `cli.js`

* cleanup

* leave out bundled files

* drop package.json from userdata paths

* fix web task

* fix editor distro

* inline version into `product.json`

* also bundle server

* t

* actually do server too

* Keep bundling nls in editor worker

Co-authored-by: Alex Dima <alexdima@microsoft.com>
2022-09-16 05:24:23 -07:00
Johannes 214e276bd5
have `compilation#transpileTask` as a separate place for tweaks 2022-06-23 17:32:20 +02:00
Tyler James Leonhardt bce2e61e04
Allow nls in the base worker (#152887)
* Add localize call to platform

* Allow to use nls in the base worker

Co-authored-by: Alex Dima <alexdima@microsoft.com>
2022-06-22 12:30:09 -07:00
Alexandru Dima 252c65540d
Adopt the same export patterns in `vs/css` as in `vs/nls` and bring over tests (#152396)
* Adopt the same export patterns in `vs/css` as in `vs/nls` and bring over tests

* Fix problem with loading nodejs modules
2022-06-17 17:12:27 +02:00
Alexandru Dima 9db5a3674e
Bring the nls loader plugin into our sources (#152338) 2022-06-16 22:01:19 +02:00
Alexandru Dima d132489cd0
Bring the css loader plugin into our sources (#152205) 2022-06-15 16:53:02 +02:00
Johannes Rieken 9e21aff42e
joh/ts transpile (#152199)
transpile-only tasks for client and extensions

* extract transpile into its own file
* add transpile-client task, polish transpiler
* add transpile-extensions, improve transpile logic
* move declaration of "const enum" above it usage so that it can be used with const-enum-inlining
* (ugly) make d.ts transpilation configurable because it is needed for extensions but a problem for client
* hack my way around so that `getOwnEmitOutputFilePath` is reusable by our transpile
* honor `noEmit` flag
2022-06-15 16:52:48 +02:00
Alexandru Dima 5e7d488b7c
Improve error message when a module cannot be bundled and exclude vs/nls from bundles (#152188) 2022-06-15 12:51:27 +00:00
Johannes 0656d21d11
auto-fixed prefer-const violation 2022-06-08 17:49:21 +02:00
Matt Bierner f71bd27ec9
Adding type annotations 2022-02-28 14:32:12 -08:00
Alex Dima bd369c638e
Add check that the editor's ESM JS files can be loaded in a browser 2022-01-25 15:19:30 +01:00
Alex Dima 3860b772e4
Revert "Simplify external .d.ts"
This reverts commit 65b10df98f.

See https://www.typescriptlang.org/docs/handbook/modules.html#export--and-import--require
2021-10-08 16:58:02 +02:00
Alex Dima 65b10df98f
Simplify external .d.ts 2021-10-08 08:51:26 +02:00
Alex Dima 96353e2bcf
Fix typo 2021-09-28 14:14:06 +02:00
Alex Dima 8d3ce8d7f5
Fix the transformation to an external module .d.ts 2021-09-21 17:20:30 +02:00
João Moreno 980becda8d main rename
fixes #116341
2021-02-14 20:10:24 +01:00
Alexandru Dima c1eb24b027
Load expensive node modules lazily 2020-12-22 19:55:56 +01:00
Martin Aeschlimann 542a82754c yarn watch: save errors in separate files, make error regex multiline aware 2020-11-20 14:06:42 +01:00
Alex Dima dd6bd3ae6a
Reduce the number of folders where we use TS 2020-09-24 17:39:48 +02:00
ChaseKnowlden e8760a5d6c Fix capitalization of GitHub org 2020-09-17 11:43:03 +02:00
Alex Dima 4578463f90
Do not tree shake interfaces or classes that extend or inherit from symbols defined in the default library 2020-05-08 14:41:03 +02:00
Martin Aeschlimann ec02bcd1cc codicon definitions in browser/ui/codicon/codicon 2020-04-17 13:39:54 +02:00
Matt Bierner 273a4a389d
Convert most ts-ignore-calls to ts-expect-error (#93617)
Changes over to use ts-expect-error: https://devblogs.microsoft.com/typescript/announcing-typescript-3-9-beta/#ts-expect-error-comments

This revealed a number of places where we no longer need to supress errors
2020-03-30 17:31:37 -07:00
Alex Dima ee64b77af9
Reduce noise in diff and use files with the same absolute imports when troubleshooting treeshaking 2020-03-05 10:25:06 +01:00
Alex Dima 58bdc8aecb
Improve troubleshooting treeshaking failures 2020-03-05 10:25:06 +01:00
Johannes Rieken 02f23e5680 remove polyfill promise 2020-03-02 15:30:43 +01:00
Johannes Rieken 27bc032975 nuke special lib options and use compiler option's lib instead 2020-03-02 13:44:22 +01:00
Johannes Rieken 8fac4133c5 adopt inline compile config for editor src task 2020-03-02 12:51:32 +01:00
Alex Dima 4d92b1d1f8
Fix minor issues 2020-02-22 16:02:23 +01:00
Alex Dima 4f21fd58a8
Move gulp specific code to gulpfile.editor.js 2020-02-22 15:01:58 +01:00
Alex Dima f81397f451
Merge remote-tracking branch 'origin/master' into monaco/ci 2020-02-22 00:45:38 +01:00
Alex Dima 65fee79198
Add types for MonacoEnvironment (microsoft/monaco-editor#1795) 2020-02-04 18:39:04 +01:00
Alexandru Dima b4a79d682a
Add getters for computed editor options (Fixes microsoft/monaco-editor#1734) 2020-01-14 16:31:16 +01:00
Alexandru Dima f3f7bc580a
Fixes microsoft/monaco-editor#1729: Fix running the build on Windows (files with \r\n) 2020-01-06 10:07:58 +01:00