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

Javascript Implementation? #97

Open
Rxann opened this issue Jul 12, 2022 · 2 comments
Open

Javascript Implementation? #97

Rxann opened this issue Jul 12, 2022 · 2 comments

Comments

@Rxann
Copy link

Rxann commented Jul 12, 2022

Hi,
I am wondering if there is a Javascript Implementation of chafa? If so this would be great!

@hpjansson
Copy link
Owner

Hi! It's possible to compile it to WebAssembly, which means you'll be able to use it in a Javascript program.

Now there are no official Wasm builds, but @oakes managed to pull it off in #41. The best I can offer right now is to follow in his footsteps.

I'm open to having a discussion on how this can be made easier; maybe we should integrate the cut-down GLib @oakes made and the config files, plus an ad-hoc build script, something like that. Ideally, ./configure would have a --with-integrated-glib switch and maybe some extra setting for Wasm output, where the config.h and such are generated by Automake, but that's a serious effort and would make configure.ac much bigger.

@hpjansson
Copy link
Owner

Javascript bindings exist now, thanks to the amazing work of Héctor Molinero Fernández! Here's his repository: https://github.com/hectorm/chafa-wasm

Please let me know if this is what you had in mind; if so we can close this issue.

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