Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add encode! and decode! #147

Open
AndrewDryga opened this issue Jun 21, 2017 · 4 comments
Open

Add encode! and decode! #147

AndrewDryga opened this issue Jun 21, 2017 · 4 comments

Comments

@AndrewDryga
Copy link

It would be really awesome to have Jiffy API fully compatible with Poison and ExJSX, so it can be used as a drop-in replacement in most of the projects.

@davisp
Copy link
Owner

davisp commented Jun 21, 2017

Not sure what this would require from Jiffy? Is the api already the same and I just need to add the ! function names that proxy through to the existing encode/decode functions or are you asking for more API option equivalence stuff?

@AndrewDryga
Copy link
Author

Adding ! functions would be a great start, but usually this means that functions without ! return {:ok, binary} or {:error, reason} (I guess {ok, Binary} and {error, Reason}` in Erlang) tuples. Since this is a breaking change I guess you can consider it only on next major update.

Other option may be adding mix.exs file and Elixir module, that will use existing Erlang jiffy implementation and provide a Poison-compatible interface, which won't break anything and will make using this package even simpler.

@davisp
Copy link
Owner

davisp commented Jun 22, 2017 via email

@AndrewDryga
Copy link
Author

See #149

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants