shared: route ref-script server helpers via tx/server (keep buyer bundle clean)
Static re-exports from tx/index.ts caused vite to trace loadEscrowScript/loadAdvertScript/buildLiveTxForPublishReferenceScripts into the buyer UI bundle, hitting the CML WASM "ESM integration proposal" limitation. Sibling builders avoid this with /* @vite-ignore */ dynamic imports; we keep symmetry by parking the helpers on a separate @marketplace/shared/tx/server entry that the buyer never imports. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -25,13 +25,13 @@ import * as ed from "@noble/ed25519";
|
||||
import { blake2b } from "@noble/hashes/blake2b";
|
||||
import { bech32 } from "bech32";
|
||||
import { LiveOgmiosProvider } from "@marketplace/shared/chain";
|
||||
import type { WalletKey } from "@marketplace/shared/tx";
|
||||
import {
|
||||
buildLiveTxForPublishReferenceScripts,
|
||||
loadEscrowScript,
|
||||
loadAdvertScript,
|
||||
pkhToEnterpriseAddress,
|
||||
} from "@marketplace/shared/tx";
|
||||
import type { WalletKey } from "@marketplace/shared/tx";
|
||||
} from "@marketplace/shared/tx/server";
|
||||
|
||||
ed.etc.sha512Sync = (...messages: Uint8Array[]): Uint8Array => {
|
||||
const h = createHash("sha512");
|
||||
|
||||
Reference in New Issue
Block a user