UNPKG

@thi.ng/geom

Version:

Functional, polymorphic API for 2D geometry types & SVG generation

20 lines (19 loc) 248 B
class Extra { constructor(body) { this.body = body; } type = "extra"; dim = 2; copy() { return new Extra(this.body); } withAttribs() { return this.copy(); } toHiccup() { return this.body; } } export { Extra };