When passing down attributes to an element, it is no use to convert a javascript object into [object Object]. This PR adds a wrapper which stringifies all objects nested under the attrs key to make passing simple serializable objects seamless to the developer.
Why the attrs key only? this is how the wrapper key that snabbdom uses for attributes and I wanted to limit the scope of these conversions.
When passing down attributes to an element, it is no use to convert a javascript object into
[object Object]
. This PR adds a wrapper which stringifies all objects nested under theattrs
key to make passing simple serializable objects seamless to the developer.Why the
attrs
key only? this is how the wrapper key that snabbdom uses for attributes and I wanted to limit the scope of these conversions.