Module

Global.Unsafe

Package
purescript-globals
Repository
purescript/purescript-globals

#unsafeStringify Source

unsafeStringify :: forall a. a -> String

Uses the global JSON object to turn anything into a string. Careful! Trying to serialize functions returns undefined

#unsafeToFixed Source

unsafeToFixed :: Int -> Number -> String

Formats Number as a String with limited number of digits after the dot.

May throw RangeError if the number of digits is not within the allowed range (standard precision range is 0 to 20, but implementations may change it)

#unsafeToExponential Source

unsafeToExponential :: Int -> Number -> String

Formats Number as String in exponential notation limiting number of digits after the decimal dot.

May throw RangeError if the number of digits is not within the allowed range (standard precision range is 0 to 20, but implementations may change it)

#unsafeToPrecision Source

unsafeToPrecision :: Int -> Number -> String

Formats Number as String in fixed-point or exponential notation rounded to specified number of significant digits.

May throw RangeError if the number of digits is not within the allowed range (standard precision range is 0 to 100, but implementations may change it)

#unsafeDecodeURI Source

unsafeDecodeURI :: String -> String

URI decoding. May throw a URIError if given a value with undecodeable escape sequences.

#unsafeEncodeURI Source

unsafeEncodeURI :: String -> String

URI encoding. May throw a URIError if given a value with unencodeable characters.

#unsafeDecodeURIComponent Source

unsafeDecodeURIComponent :: String -> String

URI component decoding. May throw a URIError if given a value with undecodeable escape sequences.

#unsafeEncodeURIComponent Source

unsafeEncodeURIComponent :: String -> String

URI component encoding. May throw a URIError if given a value with unencodeable characters.