Model - Nesting
API reference for src/schema/domains/nesting on @huukhanhnguyen/model, reachable from ./compute.
See the Guide for the ModelJSON / evaluate pipeline.
API reference
Signatures are generated from the live package .d.ts - not hand-written.
NestOptions
type
type NestOptions
// = {
parts: NestPartSpec[];
stock: {
width: number;
height: number;
};
spacing: number;
seed: number;
/** One part's evaluated (already drafting-layer-stamped) flat pattern —
* for a linear part this is its centerline + section, not an outline. */
resolvePart: (key: string) => Entity[];
partMeta: (key: string) => NestPartMeta | undefined;
/** mm — stock bar length for the 1D bin-packer. Absent/0 = no linear
* parts are placed (they're simply skipped, same fail-soft spirit as
* the 2D path's own `!stock.width` early return). */
stockLength?: number;
/** mm — saw-blade kerf consumed between adjacent cuts on the same bar. */
kerfWidth?: number;
}