Closed iand675 closed 7 years ago
@iand675 this looks good. Mind adding a test to confirm the JSON structure? Looks like I had been meaning to get around to that which would have caught this problem sooner :wink: https://github.com/toddmohney/json-api/blob/master/test/Network/JSONApi/DocumentSpec.hs#L23
Shall we rename the functions to something more intuitive?
The convention in Haskell of suffixing a function with '
means the function is strict.
@YLiLarry hmm... I think agree with the current interface.
My understanding of the prime function convention is not that the function is strict, but that the prime indicates that the function is closely related to, often derivative of another function.
In this case mkDocument
is implemented in terms of mkDocument'
which is how I would expect things to work.
@toddmohney
Fixes #27
I'm open to other approaches to extending the interface if you don't like the approach I took.