memfs
JSage
memfs | JSage | |
---|---|---|
3 | 4 | |
1,617 | 33 | |
- | - | |
9.4 | 0.0 | |
6 days ago | over 1 year ago | |
TypeScript | JavaScript | |
Apache License 2.0 | GNU General Public License v3.0 only |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
memfs
-
CoWasm: An alternative to Emscripten, based on Zig (demo: Python in the browser)
I am using the Python ecosystem (with full support for dynamic loading of C extension modules) as an initial motivating project. Also, the Python test suite is extremely useful to root out problems. I certainly hope that this can provide a more complete alternative to Emscripten to the community eventually. That said, Emscripten is huge, and the problems involved in creating a more maintainable modular WASM build tool are subtle. For example, when implementing a custom module loader for Python-wasm last week, I discovered several bugs in the memfs and unionfs Javascript libraries (https://github.com/streamich/memfs/pulls?q=is%3Apr+author%3A... and https://github.com/streamich/unionfs/pulls?q=is%3Apr+author%...). I had to learn the code sufficiently to fix all these bugs, submit PR's, etc. Emscripten has its own analogue of memfs, which is optimized specifically for WebAssembly in the browser, where memfs is a more general widely used library (with 10M+ downloads/week).
CoWasm has no support for asyncify. Where I've run into setjmp/longjmp so far, I've been rewriting the code instead. E.g., the dash shell uses setjmp/longjmp, and I'm rewriting that to use return error codes instead (see, e.g., https://github.com/sagemathinc/dash/commit/7117e1f6496728af0...).
> how would I go about porting a simple C->WASM w/ Typescript library project to CoWasm?
That's a great question, which I'm not sure how to quickly answer, so I've created a discussion item here https://github.com/sagemathinc/cowasm/discussions/40
-
Encryption in PDF Specification and my attempt to do it in pdf-lib
Looks like this whole thing was motivated by the fact that, in order to get the encrypted PDF in a Buffer like they wanted, they had to save to disk and load it back. They could have instead used an in-memory filesystem such as https://github.com/streamich/memfs and just made the existing PDF library that was almost right use that.
-
I used emscripten to port a command line program to JS/web assembly, now what?
How do I populate the input files? The filesystem API in emscripten talks about MEMFS, is that the same as this? https://github.com/streamich/memfs
JSage
-
CoWasm: An alternative to Emscripten, based on Zig (demo: Python in the browser)
Yes, porting https://SageMath.org to the browser is part of the plan, and this is a key foundation for that. I ported some of the components of Sage (e.g., https://libntl.org/) already as part of https://github.com/sagemathinc/jsage, and I don't see any fundamental obstruction to porting all of Sage, except time. It would be great if once CoWasm is more stable, I can get some help porting some components to WASM.
- SageMath is a free open-source mathematics software system
-
Tiny WASI – A tiny WASI runtime written in TypeScript
And here is the more lightweight and flexible (in some ways) one from Wasmer, before they completely rewrote it in Rust:
https://github.com/sagemathinc/JSage/tree/main/packages/wasi
It took me some work to track down the old version, fix some bugs in it, and keep it going. But I personally find the old version very useful too, and if you can see from the comments that it has an interesting history.
-
We've been lied to: JavaScript is fast
Here's a third called "JPython", which I've been writing lately for fun:
https://github.com/sagemathinc/JSage/tree/main/packages/jpyt...
What are some alternatives?
react-native-file-access - Filesystem access for React Native
Transcrypt - Python 3.9 to JavaScript compiler - Lean, fast, open! -
fs-jetpack - Better file system API for Node.js
cocalc - CoCalc: Collaborative Calculation in the Cloud
hazelcast-nodejs-client - Hazelcast Node.js Client
ElectronVisualized - Public Archive: Beautiful and Elegant Quantum Mechanics Visualization.
spacedrive - Spacedrive is an open source cross-platform file explorer, powered by a virtual distributed filesystem written in Rust.
mt63_wasm - MT63 encoder and decoder in WebAssembly
react-cool-virtual - 😎 ♻️ A tiny React hook for rendering large datasets like a breeze.
tinywasi - A tiny WASI runtime written in TypeScript
unionfs - Use multiple fs modules at once
Microsoft Automatic Graph Layout - A set of tools for graph layout and viewing