skymakerolof / dxf

DXF parser for node/browser
https://www.npmjs.com/package/dxf
MIT License
335 stars 122 forks source link

toPolyLines wrong type, is currently information.Polyline[] but toPolyLines returns { bbox, polylines } #133

Open AndreLeBlanc opened 1 year ago

AndreLeBlanc commented 1 year ago

When using the library to write a typescript program to estimate lengths of entities, I came across the following:

  return { bbox, polylines }

in the toPolyLines function

Yet in the types file we see:

  toPolylines(): Information.Polyline[];

Proposed solution:

 {bbox: bbox, polylines: Information.Polyline[]};