Skip to content

Commit

Permalink
Version Packages
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Mar 12, 2024
1 parent 85b42dc commit eba8ce6
Show file tree
Hide file tree
Showing 14 changed files with 52 additions and 55 deletions.
8 changes: 0 additions & 8 deletions .changeset/strong-pets-judge.md

This file was deleted.

8 changes: 8 additions & 0 deletions packages/astro-check/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @astrojs/check

## 0.5.8

### Patch Changes

- 85b42dc: Update to the latest version of Volar. This release fixes a few issues such as missing Prettier crashing the language server in some cases, resolutions not working correctly inside TSX files, and more.
- Updated dependencies [85b42dc]
- @astrojs/language-server@2.8.0

## 0.5.7

### Patch Changes
Expand Down
4 changes: 2 additions & 2 deletions packages/astro-check/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@astrojs/check",
"version": "0.5.7",
"version": "0.5.8",
"author": "withastro",
"license": "MIT",
"repository": {
Expand All @@ -22,7 +22,7 @@
"test:match": "pnpm run test -g"
},
"dependencies": {
"@astrojs/language-server": "^2.7.7",
"@astrojs/language-server": "^2.8.0",
"chokidar": "^3.5.3",
"fast-glob": "^3.3.1",
"kleur": "^4.1.5",
Expand Down
6 changes: 6 additions & 0 deletions packages/language-server/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @astrojs/language-server

## 2.8.0

### Minor Changes

- 85b42dc: Update to the latest version of Volar. This release fixes a few issues such as missing Prettier crashing the language server in some cases, resolutions not working correctly inside TSX files, and more.

## 2.7.7

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/language-server/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@astrojs/language-server",
"version": "2.7.7",
"version": "2.8.0",
"author": "withastro",
"license": "MIT",
"repository": {
Expand Down
8 changes: 2 additions & 6 deletions packages/language-server/src/languageServerPlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { create as createTypeScriptService } from './plugins/typescript/index.js

export function createServerOptions(
connection: Connection,
ts: typeof import("typescript")
ts: typeof import('typescript')
): ServerOptions {
return {
watchFileExtensions: [
Expand Down Expand Up @@ -64,11 +64,7 @@ export function createServerOptions(
const rootPath = projectContext.typescript.configFileName
? projectContext.typescript.configFileName.split('/').slice(0, -1).join('/')
: serviceEnv.typescript!.uriToFileName(serviceEnv.workspaceFolder);
const nearestPackageJson = ts.findConfigFile(
rootPath,
ts.sys.fileExists,
'package.json'
);
const nearestPackageJson = ts.findConfigFile(rootPath, ts.sys.fileExists, 'package.json');

const astroInstall = getAstroInstall([rootPath], {
nearestPackageJson: nearestPackageJson,
Expand Down
11 changes: 5 additions & 6 deletions packages/language-server/src/nodeServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,15 @@ const server = createServer(connection);
connection.listen();

connection.onInitialize((params) => {
const tsdk = params.initializationOptions?.typescript?.tsdk
const tsdk = params.initializationOptions?.typescript?.tsdk;

if (!tsdk) {
throw new Error('The `typescript.tsdk` init option is required. It should point to a directory containing a `typescript.js` or `tsserverlibrary.js` file, such as `node_modules/typescript/lib`.');
throw new Error(
'The `typescript.tsdk` init option is required. It should point to a directory containing a `typescript.js` or `tsserverlibrary.js` file, such as `node_modules/typescript/lib`.'
);
}

const {typescript, diagnosticMessages} = loadTsdkByPath(
tsdk,
params.locale
)
const { typescript, diagnosticMessages } = loadTsdkByPath(tsdk, params.locale);

return server.initialize(
params,
Expand Down
6 changes: 6 additions & 0 deletions packages/ts-plugin/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @astrojs/ts-plugin

## 1.6.0

### Minor Changes

- 85b42dc: Update to the latest version of Volar. This release fixes a few issues such as missing Prettier crashing the language server in some cases, resolutions not working correctly inside TSX files, and more.

## 1.5.3

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/ts-plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@astrojs/ts-plugin",
"version": "1.5.3",
"version": "1.6.0",
"description": "A TypeScript Plugin providing Astro intellisense",
"main": "dist/index.js",
"type": "commonjs",
Expand Down
6 changes: 6 additions & 0 deletions packages/vscode/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# astro-vscode

## 2.8.0

### Minor Changes

- 85b42dc: Update to the latest version of Volar. This release fixes a few issues such as missing Prettier crashing the language server in some cases, resolutions not working correctly inside TSX files, and more.

## 2.7.7

### Patch Changes
Expand Down
6 changes: 3 additions & 3 deletions packages/vscode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"color": "#17191E",
"theme": "dark"
},
"version": "2.7.7",
"version": "2.8.0",
"author": "withastro",
"license": "MIT",
"publisher": "astro-build",
Expand Down Expand Up @@ -195,8 +195,8 @@
"update-grammar-snapshots": "node ./test/grammar/test.mjs --updateSnapshot"
},
"devDependencies": {
"@astrojs/language-server": "^2.7.7",
"@astrojs/ts-plugin": "^1.5.3",
"@astrojs/language-server": "^2.8.0",
"@astrojs/ts-plugin": "^1.6.0",
"@types/glob": "^8.1.0",
"@types/mocha": "^10.0.1",
"@types/node": "^18.17.8",
Expand Down
10 changes: 5 additions & 5 deletions packages/vscode/src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
activateTsConfigStatusItem,
activateTsVersionStatusItem,
createLabsInfo,
getTsdk
getTsdk,
} from '@volar/vscode';
import * as vscode from 'vscode';
import * as lsp from 'vscode-languageclient/node';
Expand Down Expand Up @@ -72,7 +72,7 @@ export async function activate(context: vscode.ExtensionContext): Promise<LabsIn
const clientOptions = {
documentSelector: [{ language: 'astro' }],
initializationOptions,
} satisfies lsp.LanguageClientOptions
} satisfies lsp.LanguageClientOptions;
client = new lsp.LanguageClient('astro', 'Astro Language Server', serverOptions, clientOptions);
await client.start();

Expand All @@ -89,10 +89,10 @@ export async function activate(context: vscode.ExtensionContext): Promise<LabsIn
(text) => text
);

const volarLabs = createLabsInfo(protocol)
volarLabs.addLanguageClient(client)
const volarLabs = createLabsInfo(protocol);
volarLabs.addLanguageClient(client);

return volarLabs.extensionExports
return volarLabs.extensionExports;
}

export function deactivate(): Thenable<any> | undefined {
Expand Down
4 changes: 1 addition & 3 deletions packages/vscode/syntaxes/astro.tmLanguage.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
{
"name": "Astro",
"scopeName": "source.astro",
"fileTypes": [
"astro"
],
"fileTypes": ["astro"],
"injections": {
"L:(meta.script.astro) (meta.lang.json) - (meta source)": {
"patterns": [
Expand Down
26 changes: 6 additions & 20 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit eba8ce6

Please sign in to comment.