Skip to content

Commit

Permalink
[ci] yarn format
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewp authored and actions-user committed Jun 3, 2021
1 parent afc6232 commit 1dac52b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 13 deletions.
6 changes: 1 addition & 5 deletions esinstall/src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -184,11 +184,7 @@ export function isJavaScript(pathname: string): boolean {
* - BUNDLE: Install and bundle this file with Rollup engine.
* - ASSET: Copy this file directly.
*/
const bundleTypeExtensions = new Set([
'.svelte',
'.vue',
'.astro'
]);
const bundleTypeExtensions = new Set(['.svelte', '.vue', '.astro']);

export function getWebDependencyType(pathname: string): 'ASSET' | 'BUNDLE' | 'DTS' {
const ext = path.extname(pathname).toLowerCase();
Expand Down
19 changes: 11 additions & 8 deletions test/esinstall/import-astro/import-astro.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,22 @@ describe('importing .astro files', () => {
const dest = path.join(cwd, 'test-astro');

// Run Test
const { importMap: { imports }} = await runTest(['astro-components/Wow.astro'], {
cwd, dest,
const {
importMap: {imports},
} = await runTest(['astro-components/Wow.astro'], {
cwd,
dest,
rollup: {
plugins: [
{
load() {
return 'export default "so wow";'
}
}
]
}
return 'export default "so wow";';
},
},
],
},
});

expect(imports['astro-components/Wow.astro']).toBe('./astro-components/Wow.astro.js');
});
});

1 comment on commit 1dac52b

@vercel
Copy link

@vercel vercel bot commented on 1dac52b Jun 3, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.