The root tsup build bundles the CLI and SDK sources, but the CLI imports
@graph-kit/sdk and its subpaths. tsup resolves those through @graph-kit/sdk's
package.json exports, which point at dist/ files that don't exist on a clean
checkout, so the root build failed in CI.
- Add an esbuild onResolve plugin to tsup.config.ts that redirects
@graph-kit/sdk and its subpaths to their TypeScript source files, so the
root bundle inlines the SDK source instead of resolving through dist/
- Change the root build script to 'turbo run build && tsup && tsc' so the
workspace packages' dist/ outputs (needed by the SDK benchmark CI script)
are produced before the root bundle
- Rewrite .size-limit.json to reference the consolidated root dist/ outputs
(index/cli/driver/neo4j/memgraph/kuzu/falkordb) with limits set above the
measured gzipped sizes, since the old per-package dist/ paths no longer
apply
Verified clean: pnpm build (fully clean), pnpm lint (0 warnings),
pnpm typecheck (30/30), pnpm test:ci (12/12), pnpm test:root (13/13),
npx size-limit (all under limit).
What changed
Consolidates the monorepo into a single publishable
graph-kitpackage (renamed fromgraph-om) with all workspace packages bundled inside it.Details
tsup(CJS + ESM, treeshaken) producesindex/cli/driver/neo4j/memgraph/kuzu/falkordbentry points intodist/; type declarations generated viatsc -p tsconfig.decl.json(SDK source only)exportsmap,main/module/types,bin,files, anddependencies/optionalDependenciesso the root package is publishable on its ownturbototsup && tscforbuild/size/release@graph-kit/*packagesprivate: true(shipped inside the root bundle, not published separately)linkedpackage group; added a changeset for the initial public release as unscopedgraph-kitVerification
pnpm build— tsup + tsc succeed;dist/layout matches the exports mappnpm lint— 0 warningspnpm test:root— 13/13 passpnpm typecheck— 30/30 packages passSummary by CodeRabbit
graph-kitis now available as a public, unscoped package, renamed fromgraph-om.