Lossless low level DXF object model.
$ npm i @dxfom/dxf
import fs from 'fs'
import { parseDxfFileArrayBuffer } from '@dxfom/dxf/bundle.js'
const buffer = fs.readFileSync('my.dxf')
const dxf = parseDxfFileArrayBuffer(buffer.buffer)
for (const entity of dxf.ENTITIES) {
for (const [groupCode, groupCodeValue] of entity) {
console.log(groupCode, ':', groupCodeValue)
}
console.log('----')
}
See Dxf.ts.
GPL 3.0