You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We would need support for older browsers, which are not supported by buffer.js. There's better support e.g. in the buffer package in npm. Could pbf use that instead of buffer.js?
The concrete issue with Firefox < 30 is that toString cannot be overridden by buffer.js, resulting in all strings deserialising as "[object Uint8Array]" instead of the actual data.
Another browser supported by buffer but not buffer.js is IE9.
The text was updated successfully, but these errors were encountered:
I made buffer.js instead of buffer because of some performance optimizations tailored specifically for pbf, and to make the build as lightweight as possible. Not sure if it's worth supporting old browsers in this library. As a workaround, you can put a compatible Buffer into a global scope, and it will be used instead: https://github.com/mapbox/pbf/blob/master/index.js#L5
Based on the browser version usage stats, I don't think it's worth significantly complicating the code to support unused legacy versions like this. E.g. IE9's usage is 0.51%. And there's a workaround above for those who need it.
We would need support for older browsers, which are not supported by
buffer.js
. There's better support e.g. in thebuffer
package in npm. Couldpbf
use that instead ofbuffer.js
?The concrete issue with Firefox < 30 is that
toString
cannot be overridden bybuffer.js
, resulting in all strings deserialising as "[object Uint8Array]" instead of the actual data.Another browser supported by
buffer
but notbuffer.js
is IE9.The text was updated successfully, but these errors were encountered: