Closed hamishmack closed 9 years ago
I think a better idea is to use type JSArray a = JSRef [a]
. This does make [a]
a sort of default Haskell representation of an JavaScript array, but it does not prevent other type also being marshalled to JavaScript arrays.
Arrays will be
JSArray (JSRef a)
instead ofJSArray a
. This means that the access phantom typea
is not needed to make the array type.The existing code in that uses
JSArray JSString
is a bit simpler.