This library allows a variable to hold a value of any type. The name of the
module is derived from the Autoboxing concept in Java. Boxed values can be
useful when receiving external data that you do not want to thoroughly check for
errors, but rather disregard the type of some of the values obtained. For
example, you might be more interested in the structure of the received data than
the type of all of the member values. The decoder found at Boxed.Json lets
any kind of value through, allowing you to focus on the shape of the whole data
structure.
Some helper functions are provided to extract native Elm values, for example:
filterMap asFloat (Lst [Integer 1, Str "b", Double 3.01])
-- It returns [1,3.01]Note: Dict has been limited to use only String as keys
Boxed is currently holding an encapsulation of said type. (Exception made on asFloat).Note: Both Integer and Double will be able to pass as Float
Always returns a List. Consider using it along with isList.
Always returns a Dict. Consider using it along with isDict.
Return value of boxed Bool. If Boxed is holding any other type,
return False.