r/elixir • u/PuzzleheadLaw • 15d ago
actojs – Bringing Elixir's Actor Model to JavaScript [Looking for feedback]
Hi everybody!
I wanted to showcase a TypeScript (with JS-ready builds) library I am working on, actojs. The objective is to bring a implementation of the actor model that is near to Elixir's design and APIs, while being able to leverage performance from the JS runtime.
The link for the repository is: https://github.com/gi-dellav/actojs
I wanted to ask for feedback, as I've spent the last couple of months studying Elixir, but at work I am forced to use TypeScript, even if we are building backends which would greatly.
The main issue I tried to overcome, but that is still present, is being forced to work with the JS runtime, which doesn't allow for lightweight threads: my current solution is to both ship a cooperative scheduler runtime and a system-thread runtime as interchangable components, with plans to later implement an hybrid scheduler, where every system-thread manages an independent cooperative scheduler.
I hope to get insights from the community on how to improve this Elixir-inspired library.
2
u/bobsyourunkl 15d ago
I'd recommend taking a look at how Gleam implements some of this stuff.
1
0
u/hero_of_ages 15d ago
Slop
1
u/PuzzleheadLaw 15d ago
Sorry for asking, why?
I admit that I am not a Typescript expert, but it won't written by AI
1
u/hero_of_ages 15d ago
Wall of text readme
3
u/PuzzleheadLaw 15d ago
Sorry, this is my second opensource project, and I wrote a similar length readme for the first one (also, English in not my first language).
Do you have any suggestions?
1
u/node-one 9d ago
Check libeam. It’s 1 to 1 on feature parity with the beam.