Files
market/next.config.mjs
T
zeekayandHanzo Dev ceb3c7990a fix(market): the /genesis fix has never shipped — repair the image build
/genesis reads totalMinted() and totalLuxLocked() live and says so when the
contract does not answer. That landed in 9b7c25f. It has never reached a
browser: a page-load trace of https://app.lux.market/genesis right now still
renders the hard-coded tier table —

  Genesis   Permanently Locked 1,000,000,000 LUX   Max Supply: 10
  Validator Permanently Locked   100,000,000 LUX   Max Supply: 100
  Mini      Permanently Locked    10,000,000 LUX   Max Supply: 1,000
  Nano      Permanently Locked     1,000,000 LUX   Max Supply: 10,000

— 40B LUX of "permanently locked" behind 0x004287c4..76c6, which has NO CODE:
eth_getCode on https://api.lux.network/v1/bc/C/rpc returns "0x" at block
1098195, positive controls WLUX 0x4888E4a2.. -> 3462 hex chars and Multicall3
0xd25F88CB.. -> 2592.

The live pods run ghcr.io/luxfi/market:1.0.31-amd64, built 2026-06-25. Tags
v1.0.32 through v1.1.4 produced no image at all: docker.yml carried a
top-level `permissions:` block alongside `secrets: inherit` on a `uses:`,
which fails the run at 0s with "workflow file issue" before any job starts —
and it targeted `["self-hosted","linux","amd64"]`, a label array that names
hanzoai-org scale sets not visible from luxfi. Both fixed by using the shape
that is actually building luxfi/finance: same-org reusable, no permissions
block, ARC scale-set name as a scalar label.

- next.config.ts -> next.config.mjs: Next 15's TS config loader calls
  ts.sys.fileExists off the app's own typescript, which TypeScript 7 does not
  export, so `next build` died before the first request. A config file that
  annotates one object literal does not need types.
- next 15.5.0 -> 15.5.22, @luxfi/ui 7.4.9 -> 7.4.10 (patch only).

Co-authored-by: Hanzo Dev <[email protected]>
2026-07-28 00:26:30 -07:00

42 lines
1.8 KiB
JavaScript

// Plain ESM, not TypeScript, on purpose.
//
// Next 15's `next.config.ts` loader calls `ts.sys.fileExists` / `ts.findConfigFile`
// off the app's own `typescript`. This repo is on TypeScript 7 (native preview),
// whose module exports neither, so booting died before the first request with
// `TypeError: Cannot read properties of undefined (reading 'fileExists')` and
// `Failed to load next.config.ts`. A config file gains nothing from types it
// only uses to annotate one object literal.
import path from 'path'
import { withLuxUi } from '@luxfi/ui/next'
// `withLuxUi` is the ONE place the gui engine's bundler wiring lives — transpile
// list, react-native → react-native-web alias in both bundlers, platform
// defines. Every Next surface needed the identical incantation; the ones that
// hand-rolled it each transpiled a different subset, which is how one app
// renders a Sheet and the next throws on the same component.
const nextConfig = {
output: 'export',
outputFileTracingRoot: path.resolve(import.meta.dirname ?? __dirname),
reactStrictMode: true,
typescript: { ignoreBuildErrors: false },
eslint: { ignoreDuringBuilds: true },
images: {
unoptimized: true,
remotePatterns: [
{ protocol: 'https', hostname: '*.lux.network' },
{ protocol: 'https', hostname: 'ipfs.io' },
{ protocol: 'https', hostname: '*.ipfs.io' },
{ protocol: 'https', hostname: 'cloudflare-ipfs.com' },
{ protocol: 'https', hostname: 'arweave.net' },
{ protocol: 'https', hostname: 'gateway.pinata.cloud' },
{ protocol: 'https', hostname: 'dweb.link' },
{ protocol: 'https', hostname: 'w3s.link' },
{ protocol: 'https', hostname: 'nft-cdn.alchemy.com' },
{ protocol: 'https', hostname: '*.nftstorage.link' },
],
},
}
export default withLuxUi(nextConfig)