feat(medusa): Improve add line item to cart perf and transaction management + clustering start command (#5701)
This commit is contained in:
committed by
GitHub
parent
a458cd144d
commit
6975eacb33
@@ -15,7 +15,9 @@ export async function build({
|
||||
options,
|
||||
reporting = "fancy",
|
||||
}: BuildArgs) {
|
||||
await createCacheDir({ appDir, plugins })
|
||||
if (!process.env.PLUGIN_ADMIN_UI_SKIP_CACHE) {
|
||||
await createCacheDir({ appDir, plugins })
|
||||
}
|
||||
|
||||
const cacheDir = path.resolve(appDir, ".cache")
|
||||
const entry = path.resolve(cacheDir, "admin", "src", "main.tsx")
|
||||
|
||||
@@ -5,6 +5,10 @@ import { createEntry } from "./create-entry"
|
||||
import { logger } from "./logger"
|
||||
|
||||
async function copyAdmin(dest: string) {
|
||||
if (process.env.PLUGIN_ADMIN_UI_SKIP_CACHE) {
|
||||
return true
|
||||
}
|
||||
|
||||
const adminDir = path.resolve(__dirname, "..", "ui")
|
||||
const destDir = path.resolve(dest, "admin")
|
||||
|
||||
|
||||
@@ -13,6 +13,10 @@ import {
|
||||
const FILE_EXT_REGEX = /\.[^/.]+$/
|
||||
|
||||
async function copyLocalExtensions(src: string, dest: string) {
|
||||
if (process.env.PLUGIN_ADMIN_UI_SKIP_CACHE) {
|
||||
return true
|
||||
}
|
||||
|
||||
try {
|
||||
await fse.copy(src, dest, {
|
||||
filter: copyFilter,
|
||||
|
||||
Reference in New Issue
Block a user