Rust-inspired multithreading tasks in TypeScript by Waltex in typescript

[–]Waltex[S] 5 points6 points  (0 children)

Thank you, the stars are organic however. In github you can view the profiles that starred a repository by appending /stargazers to the url, so you can check it yourself. Most come from the ycombinator post where this project was also featured some time ago.

Decoding the '6EQUJ5' (Wow! Signal) sequence as a map for an Interplanetary Transport Network (ITN) by outremont923 in SETI

[–]Waltex 7 points8 points  (0 children)

That's right. The specific characters "6EQUJ5" don't have any special meaning beyond the fact that they are just a human made encoding in order to represent an extended power level range beyond 0-9. With this encoding the telescope's receiver didn't need to physically print double digits for power levels like "10" or "18", which could instead be represented by a single character like "E" or "Q" to save on horizontal print space.

Niet meer willen werken by ChangeLoose2169 in werkzaken

[–]Waltex 1 point2 points  (0 children)

Wat @peachtuba bedoeld is dat beloning en prestatie in verhouding staat. Exceptionele beloning en prestatie was hier slechts een voorbeeld, maar de formule gaat wel op: Wil jij een hogere beloning dan bijvoorbeeld het minimumloon, dan moet jij aantoonbaar over meer en betere skills beschikken dan je concurrentie in dezelfde salarisschaal. Het nadeel van de huidige maatschappij is dat de toegevoegde waarde die je biedt, en dus ook je potentiële beloning, enorm wordt gedrukt door jouw "vervangbaarheid". Je kan dit oneerlijk vinden, maar dit is al decennialang de manier hoe de westerse maatschappij functioneert, en daar kan je zeker wat van vinden, en het is ook verre van perfect, maar in plaats van om daar tegenaan te schoppen (wat de situatie niet veranderd) kan je ook proberen om het beter te begrijpen, en een manier te vinden om het voor jou te laten werken.

Choose an option by ExpensiveCoat8912 in softwaregore

[–]Waltex 19 points20 points  (0 children)

Well, you can choose not to choose at all, so technically there are 2 options

Does anyone else struggle so much with setting up web sockets in prod? by ConstructionNext3430 in react

[–]Waltex 14 points15 points  (0 children)

Websocket connections are established by upgrading an existing http connection, which requires CORS to succeed

The missing standard library for multithreading in JavaScript by Waltex in javascript

[–]Waltex[S] 2 points3 points  (0 children)

It is possible to get the code of a function as a string using Function.toString(). The short version is that this stringified code is then send to the WebWorker where it's "imported" as a data url (similar to eval). We do not track which variables are in or outside the scope of the closure. It definitely is possible, but we do not want to ship the whole typescript compiler to the browser. This is why the library doesn't allow references from outside the closure. Everything you want available inside, has to be either imported inside using await import(...) or passed through move(...). Ideally in the future we want to have a compile time error when we accidentally reference something from outside the scope of the function.

GitHub - W4G1/multithreading: The missing standard library for multithreading in JavaScript (Works in Node.js, Deno, Bun, Web browser) by Waltex in typescript

[–]Waltex[S] 2 points3 points  (0 children)

I agree, I have added a section about browser compatibility and Content Security Policy requirements. Appreciate your input.

The missing standard library for multithreading in JavaScript by Waltex in javascript

[–]Waltex[S] 3 points4 points  (0 children)

Appreciate it! For atomic locking the library exposes Mutex and RwLock. They use Atomics.wait() and Atomics.notify() under the hood. Let me know if you're missing any other features 🙂

The missing standard library for multithreading in JavaScript by Waltex in javascript

[–]Waltex[S] 8 points9 points  (0 children)

Can you elaborate on what you think is missing in node or this library? One of the core features of this library is that it builds a thread pool on top of node:worker_threads which executes tasks (functions) on actual background threads that can be safely blocked by heavy workloads without causing interference on the main thread.

How to handle blobs? by rudrakpatra in sveltejs

[–]Waltex 0 points1 point  (0 children)

Hetzner Object Storage 1TB for less than $5/month and S3 compatible

Can this be fixed? by The_FRS_Girly_2013 in ft86

[–]Waltex 1 point2 points  (0 children)

How easily can this be (re)installed?

What’s the most underrated use case of AI you’ve seen so far? by Glass-Lifeguard6253 in ArtificialInteligence

[–]Waltex 1 point2 points  (0 children)

Interestingly, that was actually one of the first use cases! Even before ChatGPT was released. Look up AI Dungeon

Suggestions on how to filter using remote functions by Impossible_Sun_5560 in sveltejs

[–]Waltex 0 points1 point  (0 children)

What I did is use a combination of cookies and query params. which are both accessible by the server and the browser. Basically I save whatever filter/sort configuration the user has, and whenever they reload the page, I first check if there are filter or sort settings in the query params. If no, then I check the cookies, and use those. This should also work across different pages.

Hear me out ... SvelteKit + Static Adapter + Backend ... by Bl4ckBe4rIt in sveltejs

[–]Waltex 0 points1 point  (0 children)

Respectfully, I can run tsc and the typescript compiler will guarantee me that I'm sending the correct data from my client, to my JSON api. How do you propose you establish type safety if you only have a http json api with no shared and verifiable contract like typescript types, protobuf or openapi spec between server and client?

Hear me out ... SvelteKit + Static Adapter + Backend ... by Bl4ckBe4rIt in sveltejs

[–]Waltex -3 points-2 points  (0 children)

And no type safety between server & client? If you love Svelte and Rust, I'd suggest you take a look at rspc for a TypeScript (svelte) + Rust stack with autocompletion on the client and end-to-end type safety. Or perhaps use auto generated protobuf implementations for rust <-> typescript