expect(fn).toHaveBeenCalledTimes(1)
observed[-1] = 'x'
expect(fn).toHaveBeenCalledTimes(1)
+ observed[NaN] = 'x'
+ expect(fn).toHaveBeenCalledTimes(1)
})
describe('Array methods w/ refs', () => {
toTypeString(val) === '[object Object]'
export const isIntegerKey = (key: unknown) =>
- isString(key) && key[0] !== '-' && '' + parseInt(key, 10) === key
+ isString(key) &&
+ key !== 'NaN' &&
+ key[0] !== '-' &&
+ '' + parseInt(key, 10) === key
export const isReservedProp = /*#__PURE__*/ makeMap(
'key,ref,' +