-
Type: New Feature
-
Resolution: Unresolved
-
Priority: Minor - P4
-
None
-
Affects Version/s: None
How are you using Mongo? What version of the server and driver are you using?
Have a client-side application where I want to serialize raw data using the extended-json in order to send data to the backend. That data contains objects with explicit undefined values. I also may have a case where the data contains explicit null values
{zig: "zag", foo: undefined, bar: null}
What is the feature/improvement you would like?
I would like to be able to serialize the above with EJSON.stringify to
{zig: "zag", bar: null}
Ideally the EJSON options includes an `ignoreUndefined` property like the regular serialize function.
What use case would this feature/improvement enable?
More explicit intention in encoding/serializing with the EJSON API
Current workaround is to have some singleton represent values I would actually want as null, and have a replacer handle converting them to null and excluding undefines.
- depends on
-
NODE-4222 Investigate NODE-4221 - EJSON stringify support ignoreUndefined
- Closed