jonericcook

jonericcook

Does anyone think it would be possible to put the bun JS runtime (written in Zig) in a NIF via Zigler?

I have a crazy question - does anyone think it would be possible to put the bun JS runtime (written in Zig) in a NIF via Zigler.

If that’s possible could you run JS files without needing Node on the machine?

bun.sh
zigler

Marked As Solved

zambal

zambal

bun.js is AFAIK only available as standalone executable and not as a library, so I don’t think that’s possible. Best you can do is writing a port, as you can do with any executable

Also Liked

joey_the_snake

joey_the_snake

My motto is: you never know until you try it in production. So my advice is to put it in your company’s most critical application as a test.

14
Post #2
ityonemo

ityonemo

Before you get too deep into it: I’m also not kidding when I say that zigler 0.10 will be different =D

But especially, resources, which this depends on are going to look something like this. I’m still hashing out the API on this so even this is likely to change.

woutdp

woutdp

Yes 40ms in dev, but about 8ms in production which is ok. In dev I think it’s because the cache gets reset every time, on production there’s caching going on and it’s way better.

And indeed I was interested in the port to Node solution instead of using elixir-nodejs. Maybe it’s faster I’m not sure. But also if Bun worked with Zigler that would be amazing. Seems it should be possible

Where Next?

Popular in Questions Top

Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
shahryarjb
Hello, I get Persian date from my client and convert it to normal calendar like this: def jalali_string_to_miladi_english_number(persi...
New
bsollish-terakeet
Credo is smart enough to check for (something like) this: assert length(the_list) == 0 with this response: Checking if an enum is empt...
New
openscript
Hello! Sorry for this astonishing simple question, but I’m really stuck. I try to set up the intellij-elixir plugin, but I don’t know ho...
New
joaquinalcerro
Hi there, I am working with Ecto-Postgresql and I need to call all of the records from a specific table but the table has 40,000 record...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
Werner
Hi, I’m using Ubuntu 18.04 and after updating to OTP-24.0 yesterday i have this warning when I run “mix local.hex”: 14:57:30.512 [warn] ...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
belgoros
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New

Other popular topics Top

Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
openscript
Hello! Sorry for this astonishing simple question, but I’m really stuck. I try to set up the intellij-elixir plugin, but I don’t know ho...
New
joaquinalcerro
Hi there, I am working with Ecto-Postgresql and I need to call all of the records from a specific table but the table has 40,000 record...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? https://hexdocs.pm/ecto/Ecto.Repo.h...
New
AstonJ
We’ve put together this wiki for Phoenix LiveView - please feel free to add any info you feel is worth including. What is Phoenix LiveV...
New
lanycrost
Hi everyone! I need implement if…else if…else condition from my elixir code, and anymore of this control flow structures not work proper...
New

We're in Beta

About us Mission Statement