Skip to content

Commit 89c723c

Browse files
committed
fix: flowbite import issue in playground
1 parent 50cb347 commit 89c723c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/repl/src/lib/workers/bundler/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -443,7 +443,8 @@ async function get_bundle(
443443
glsl,
444444
loop_protect,
445445
replace({
446-
'process.env.NODE_ENV': JSON.stringify('production')
446+
'process.env.NODE_ENV': JSON.stringify('production'),
447+
'import.meta.env.MODE': JSON.stringify('development')
447448
}),
448449
{
449450
name: 'css',

packages/repl/src/lib/workers/npm.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ export function resolve_subpath(pkg: Package, subpath: string): string {
200200

201201
export function normalize_path(pkg: Package, path: string, importee: string, importer: string) {
202202
for (const suffix of ['', '.js', '.mjs', '.cjs', '/index.js', '/index.mjs', '/index.cjs']) {
203-
let with_suffix = path + suffix;
203+
let with_suffix = (path + suffix).replace(/\/+/g, '/');
204204

205205
if (pkg.meta.browser) {
206206
with_suffix = pkg.meta.browser[`./${with_suffix}`]?.replace('./', '') ?? with_suffix;

0 commit comments

Comments
 (0)