Skip to content

Commit f300c4b

Browse files
authored
Merge pull request #389 from bichikim/dev
Dev
2 parents f821f2d + ab6e531 commit f300c4b

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

apps/bplan-client/build-hot-fix.mjs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
/* eslint-disable no-tabs,max-len,prettier/prettier,unicorn/prevent-abbreviations */
22
import nodeFs from 'node:fs'
33
import nodePath from 'node:path'
4-
import {fileURLToPath, URL} from 'node:url'
54

65
const fix = async () => {
7-
const src = nodePath.resolve('.output/server/chunks/nitro/nitro.mjs')
6+
const src = process.env.VERCEL === '1' ? nodePath.resolve('.vercel/output/functions/__nitro.func/chunks/nitro/nitro.mjs') : nodePath.resolve('.output/server/chunks/nitro/nitro.mjs')
87
const scriptJs = await nodeFs.promises.readFile(src, 'utf8')
98
await nodeFs.promises.writeFile(src, scriptJs.replace(`
109
function getDefaultExportFromNamespaceIfNotNamed (n) {

apps/bplan-client/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@apps/bplan-client",
33
"type": "module",
44
"scripts": {
5-
"build": "vinxi build && cd .vercel/output/static && ls -a",
5+
"build": "vinxi build && node build-hot-fix.mjs",
66
"dev": "vinxi dev --host ",
77
"start": "node ./.output/server/index.mjs",
88
"fix": "node build-hot-fix.mjs",

0 commit comments

Comments
 (0)