Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wasm Git #2

Open
Jean-Baptiste-Lasselle opened this issue Sep 10, 2023 · 3 comments
Open

Wasm Git #2

Jean-Baptiste-Lasselle opened this issue Sep 10, 2023 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@Jean-Baptiste-Lasselle
Copy link

Il est possible, dans un projet Astro Typescript, d'importer un ibnaire wasm (utiliser comme dépendance import something from 'my_wasm_package').

Pour utiliser un wasm comme dépendance d'un priojet astro, voici quelques référecnes :

image

GIt web worker

@BorisTherin
Copy link

Bien, j'ai cloné https://github.com/petersalomonsen/wasm-git, mais "ça ne compile pas", j'aurais besoin que tu regardes à installer ce repo.

En gros, chaques fichiers lg2.js & lg2.wasm dans les examples, ne sont que des liens symboliques ne menant vers rien.
J'ai essayé emscripten/build.sh, mais bien sur mon 'environnement' est a la rue niveau compilation.
il y'as des forks récents & anciens, mais je n'ai pas trouvé ces fichiers non plus sur les quelques uns que j'ai parcourrus.

refs :
petersalomonsen/wasm-git#84
petersalomonsen/wasm-git#32
https://www.jsdelivr.com/package/npm/wasm-git

j'ai donc copié ces fichiers à la main comme suggéré dans la derniere issue, mais ca ne semble pas entrer dans les 'industrials best practices', & je continus mon deploiement.

voila, si tu pouvais voir à ce qui j'ai 'esquiver' et remettre le tout sur les rails, je ne suis pas encore pret pour le chapitre compilation& mon env. de dev. non plus

aussi:

 libgit2 is Copyright (C) the libgit2 contributors,
 unless otherwise stated. See the AUTHORS file for details.

 Note that the only valid version of the GPL as far as this project
 is concerned is _this_ particular version of the license (ie v2, not
 v2.2 or v3.x or whatever), unless explicitly otherwise stated.``` 

@BorisTherin
Copy link

issue des plus interressante :
petersalomonsen/wasm-git#72

You can also alter the XMLHttpRequest.prototype.open in the worker to set the request header with bearer token or basic auth. This is how I do it in WebAssembly Music:

aussi:

@BorisTherin
Copy link

avec serve examples & lg2.js + lg2.wasm copiés dans examples/

image

Donc je vais prendre ce repertoire examples & le porter dans un astro@latest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants