diff --git a/packages/astro/src/vite-plugin-astro/index.ts b/packages/astro/src/vite-plugin-astro/index.ts index db1b16a775..e960067355 100644 --- a/packages/astro/src/vite-plugin-astro/index.ts +++ b/packages/astro/src/vite-plugin-astro/index.ts @@ -50,12 +50,12 @@ export default function astro({ config, logging }: AstroPluginOptions): vite.Plu async resolveId(id, from) { // If resolving from an astro subresource such as a hoisted script, // we need to resolve relative paths ourselves. - if(from) { + if (from) { const { query: fromQuery, filename } = parseAstroRequest(from); - if(fromQuery.astro && isRelativePath(id)) { + if (fromQuery.astro && isRelativePath(id)) { const resolvedURL = new URL(id, `file://${filename}`); const resolved = resolvedURL.pathname; - if(isBrowserPath(resolved)) { + if (isBrowserPath(resolved)) { return slash(fileURLToPath(new URL('.' + resolved, config.projectRoot))); } return slash(fileURLToPath(resolvedURL)); diff --git a/packages/astro/test/lit-element.test.js b/packages/astro/test/lit-element.test.js index 9d73a50deb..395eaf2e52 100644 --- a/packages/astro/test/lit-element.test.js +++ b/packages/astro/test/lit-element.test.js @@ -2,7 +2,7 @@ import { expect } from 'chai'; import cheerio from 'cheerio'; import { loadFixture } from './test-utils.js'; -describe('LitElement test', function() { +describe('LitElement test', function () { this.timeout(30000); let fixture;