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
#50 incorrectly altered the original types for fromPairs, keys, toPairs and toPairsIn.
The implementation of these functions filter out symbol keys via for ... in or Object.keys. The original types captured this fact. The altered types do not. This has implications for operations that work with the outputs of these functions that expect symbol key types to be excluded.
While looking into this, I found out it's worse than just symbols. The current typing for toPairs includes any non-enumerable property in its output, including class methods!
Problem
#50 incorrectly altered the original types for
fromPairs
,keys
,toPairs
andtoPairsIn
.The implementation of these functions filter out symbol keys via
for ... in
or Object.keys. The original types captured this fact. The altered types do not. This has implications for operations that work with the outputs of these functions that expect symbol key types to be excluded.Sandbox Demo: https://stackblitz.com/edit/vitejs-vite-tqnrhv?file=src%2Framda-demo.ts&terminal=dev
Implementation References
The text was updated successfully, but these errors were encountered: