Skip to content

Commit e70b478

Browse files
committed
fix: default_ to _default
1 parent 596aca3 commit e70b478

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

packages/svelte/test/helpers.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import * as fs from 'node:fs';
22
import * as path from 'node:path';
3-
import glob from 'tiny-glob/sync';
4-
import colors from 'kleur';
3+
54
import { assert } from 'vitest';
5+
import colors from 'kleur';
66
import { compile } from 'svelte/compiler';
77
import { fileURLToPath } from 'node:url';
8+
import glob from 'tiny-glob/sync';
89

910
export function try_load_json(file) {
1011
try {
@@ -158,8 +159,8 @@ export function create_loader(compileOptions, cwd) {
158159
)
159160
.replace(
160161
/^import (\w+, )?{([^}]+)} from ['"](.+)['"];?/gm,
161-
(_, default_, names, source) => {
162-
const d = default_ ? `default: ${default_}` : '';
162+
(_, _default, names, source) => {
163+
const d = _default ? `default: ${_default}` : '';
163164
return `const { ${d} ${names.replaceAll(
164165
' as ',
165166
': '

0 commit comments

Comments
 (0)