boyanio / angular-wasm Goto Github PK
View Code? Open in Web Editor NEWExamples of how to use WebAssembly within Angular
Home Page: https://boyan.io/angular-wasm/
License: MIT License
Examples of how to use WebAssembly within Angular
Home Page: https://boyan.io/angular-wasm/
License: MIT License
When I used the latest master branch, and run npm run wasm, I am getting the below error
Compiling wasm source for 3d-cube
docker run --rm -v C:\Users\Phanindra\Downloads\angular-wasm-master\angular-wasm-master:/src emscripten/emsdk emcc -Os src/app/wasm/3d-cube/soil/libSOIL.bc src/app/wasm/3d-cube/3d-cube.c -o src/assets/wasm/3d-cube.js -s LEGACY_GL_EMULATION=1 -Isrc/app/wasm/3d-cube/soil -s EXTRA_EXPORTED_RUNTIME_METHODS="['ccall']" -s FORCE_FILESYSTEM=1 -s MODULARIZE=1 -s EXPORT_NAME="Cube3dModule"
'docker' is not recognized as an internal or external command,
operable program or batch file.
child_process.js:674
throw err;
Hi!
it would be great to have a sample that uses complex types to pass in and out data from Angular to WASM.
Thanks.
Hi,
Awesome project, worked out of the box! (only issue I have is that "Home" routing does not work)
I'm new to WebAssemblies (and to be honest, to Angular as well) but have a fairly good understanding of how things work and bind together (for both frameworks).
I'm trying to understand how the 3d-cube
example works, but I can't figure out a few things:
How is main(argc, argv)
being invoked?
After writing the above question I paused writing and started digging a bit more to figure this one on my own, so it would be nice to get a confirmation:
Each of the objects extend
EmWasmComponent
which callsinstantiateJs
to creates ascript
element in the HTML document which reference the path to the JS file that was created byemcc
. This JS code invokesmain
How is the canvas
of the 3d-cube bound to OpenGL's texture?
Thanks
Hi,
I was trying to load https://boyan.io/angular-wasm/fibonacci, and only under Chrome has worked.
I tried with the newest Firefox: 68.0.2 (64-bit). I tried with Edge version (can't find the exact version).
I tried with Chrome: 76.0.3809.100 (Official Build) (64-bit). So only with chrome is Fibonacci working... Firefox is frozen, Edge can load the results once, then i should restart for new success. I tried under Windows 10 Home, but i tried with Firefox under Ubuntu 16.04 LTS as well. Under Linux it wasn't working as well. I tried to compile your code from master, and the same symptoms I have experienced. I used angular CLI version 8, but with package.json from master. It's very pitty because there are very very few examples can be found about angular with webassambly...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.