diff --git a/lerna.json b/lerna.json index ae71dbae7b..552757f227 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,10 @@ { "ignoreChanges": ["**/test/**", "**/*.md"], "useWorkspaces": true, - "version": "4.0.0" + "version": "4.0.0", + "command": { + "run": { + "npmClient": "yarn" + } + } } diff --git a/packages/astro/src/@types/compiler.d.ts b/packages/astro/src/@types/compiler.d.ts deleted file mode 100644 index 213e1c5039..0000000000 --- a/packages/astro/src/@types/compiler.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -declare module '@astrojs/compiler' { - export type Platform = 'browser' | 'node' | 'neutral'; - export type SourceMap = any; - - export interface TransformOptions {} - - export interface TransformResult { - code: string; - map: SourceMap; - warnings: any[]; - } - - export interface TransformResults { - js: TransformResult; - css?: TransformResult; - } - - // This function transforms a single JavaScript file. It can be used to minify - // JavaScript, convert TypeScript/JSX to JavaScript, or convert newer JavaScript - // to older JavaScript. It returns a promise that is either resolved with a - // "TransformResult" object or rejected with a "TransformFailure" object. - // - // Works in node: yes - // Works in browser: yes - export declare function transform(input: string, options?: TransformOptions): Promise; - - // This configures the browser-based version of astro. It is necessary to - // call this first and wait for the returned promise to be resolved before - // making other API calls when using astro in the browser. - // - // Works in node: yes - // Works in browser: yes ("options" is required) - export declare function initialize(options: InitializeOptions): Promise; - - export interface InitializeOptions { - // The URL of the "astro.wasm" file. This must be provided when running - // astro in the browser. - wasmURL?: string; - - // By default astro runs the WebAssembly-based browser API in a web worker - // to avoid blocking the UI thread. This can be disabled by setting "worker" - // to false. - worker?: boolean; - } -} diff --git a/packages/astro/src/runtime/hmr.ts b/packages/astro/src/runtime/hmr.ts index c64ddb6d75..23c48d5e71 100644 --- a/packages/astro/src/runtime/hmr.ts +++ b/packages/astro/src/runtime/hmr.ts @@ -1,4 +1,4 @@ -import 'vite/client'; +import '@vite/client'; if (import.meta.hot) { const parser = new DOMParser(); diff --git a/packages/astro/src/runtime/ssr.ts b/packages/astro/src/runtime/ssr.ts index 26fc3964e0..8f0e5146c7 100644 --- a/packages/astro/src/runtime/ssr.ts +++ b/packages/astro/src/runtime/ssr.ts @@ -49,7 +49,7 @@ export async function renderAstroComponent(component: InstanceType