-
-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Closed
Description
https://github.com/reduxjs/redux/blob/0e8a7b00db58796f7a7adef6ac9ebed9420c18cb/src/utils/isPlainObject.ts#L5C1-L14C2
I just upgraded the package to @reduxjs/toolkit@2.0.1 and react-redux@9.0.1 today, and then I found that the console reported an error, A non-serializable value was detected in the state, in the path. Finally, I found that it was because the object I created through Object.create(null) did not pass the isPlainObject function check. I want to know if this is correct, um... Do not want users to use objects created by Object.create(null) or is this function check not comprehensive enough?
console.log( {} ) // true
console.log( isPlainObject(Object.create(null)) ) // false ???
Metadata
Metadata
Assignees
Labels
No labels