mirror of
https://github.com/coder/code-server.git
synced 2026-11-02 22:09:11 +01:00
Fix Typescript extension not loading
This commit is contained in:
@@ -30,6 +30,11 @@ Code v1.141.0
|
||||
workbench storage on the remote server instead of browser storage. Use this if
|
||||
you want to share storage between multiple devices.
|
||||
|
||||
### Fixed
|
||||
|
||||
- The Typescript extension was trying to load as a browser extension even though
|
||||
we build the remote server version, causing it to fail to activate.
|
||||
|
||||
### Changed
|
||||
|
||||
- Update to Code 1.141.0
|
||||
|
||||
@@ -58,10 +58,17 @@ main() {
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Add the date, our name, links, enable telemetry (this just makes telemetry
|
||||
# available; telemetry can still be disabled by flag or setting), and
|
||||
# configure trusted extensions (since some, like github.copilot-chat, never
|
||||
# ask to be trusted and this is the only way to get auth working).
|
||||
# Modify the product.json:
|
||||
# - Add the date
|
||||
# - Set the code-server name.
|
||||
# - Add our links
|
||||
# - Enable telemetry (this just makes telemetry available; telemetry can still
|
||||
# be disabled by flag or setting)
|
||||
# - Configure trusted extensions (since some, like github.copilot-chat, never
|
||||
# ask to be trusted and this is the only way to get auth working).
|
||||
# - Make Typescript server plugins run in the workspace. We build the remote
|
||||
# server version, so there is no browser distribution, and this key is not
|
||||
# added automatically.
|
||||
#
|
||||
# This needs to be done before building as Code will read this file and embed
|
||||
# it into the client-side code.
|
||||
@@ -103,6 +110,9 @@ main() {
|
||||
],
|
||||
"aiConfig": {
|
||||
"ariaKey": "code-server"
|
||||
},
|
||||
"extensionPointExtensionKind": {
|
||||
"typescriptServerPlugins": ["workspace"]
|
||||
}
|
||||
}
|
||||
EOF
|
||||
|
||||
17
test/e2e/typescript.test.ts
Normal file
17
test/e2e/typescript.test.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { promises as fs } from "fs"
|
||||
import * as path from "path"
|
||||
import { describe, test } from "./baseFixture"
|
||||
|
||||
const args = ["--disable-workspace-trust"]
|
||||
|
||||
describe("typescript extension", args, {}, () => {
|
||||
test("should load as a workspace extension", async ({ codeServerPage }) => {
|
||||
const dir = await codeServerPage.workspaceDir
|
||||
const file = path.join(dir, "foo.ts")
|
||||
await fs.writeFile(file, 'const n: number = "x"')
|
||||
await codeServerPage.openFile(file)
|
||||
|
||||
await codeServerPage.executeCommandViaMenus("Developer: Show Running Extensions")
|
||||
codeServerPage.page.getByLabel("typescript-language-features").getByText("localhost:").waitFor()
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user