rtfeldman / seamless-immutable

Immutable data structures for JavaScript which are backwards-compatible with normal JS Arrays and Objects.
BSD 3-Clause "New" or "Revised" License
5.36k stars 194 forks source link

special-case errors #212

Closed lukewestby closed 7 years ago

lukewestby commented 7 years ago

Hey! We're working with some folks who want to bring seamless-immutable into their stack, and as part of setting things up we found that Error objects come out the other side of Immutable() as empty objects. Error properties are exposed as getters on the prototype so the standard method of copying objects doesn't work out.

Thanks Richard!

rtfeldman commented 7 years ago

Seems reasonable!

rtfeldman commented 7 years ago

@lukewestby published as 7.1.2