
Product
Rust Support Now in Beta
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.
@biscuit-auth/web-components
Advanced tools
This repo is part of the [eclipse biscuit](https://github.com/biscuit-auth/biscuit) project.
biscuit-web-components
This repo is part of the eclipse biscuit project.
Biscuit web components are tools used to provide in-browser biscuit tooling. See documentation
Tree-sitter is packaged in a way that makes it difficult to load it up with wds
, it is packaged as a CommonJS module (modifying a module.exports
object) and as such does not play well with es modules.
The simplest solution I have found is to turn the CommonJS module into an ES module by adding the following at the end of the file:
await TreeSitter.init({
locateFile(scriptName, scriptDirectory) {
return "/assets/tree-sitter.wasm";
}
});
export const Parser = TreeSitter;
This also calls init
once, with the proper location of the wasm file.
So to update tree-sitter
:
npm install --no-save web-tree-sitter
(check if that’s the correct version)cp node_modules/web-tree-sitter/tree-sitter.wasm assets/
cp node_modules/web-tree-sitter/tree-sitter-web.d.ts ./tree-sitter.d.ts
tree-sitter.d.ts
declare module
scopeexport = Parser
export
in front of class Parser
export
in front of namespace Parser
cp node_modules/web-tree-sitter/tree-sitter.js ./
cat << 'EOF' >> tree-sitter.js await TreeSitter.init({ locateFile(scriptName, scriptDirectory) { return "/assets/tree-sitter.wasm"; } }); export const Parser = TreeSitter; EOF
FAQs
This repo is part of the [eclipse biscuit](https://github.com/biscuit-auth/biscuit) project.
The npm package @biscuit-auth/web-components receives a total of 36 weekly downloads. As such, @biscuit-auth/web-components popularity was classified as not popular.
We found that @biscuit-auth/web-components demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.
Product
Socket Fix 2.0 brings targeted CVE remediation, smarter upgrade planning, and broader ecosystem support to help developers get to zero alerts.
Security News
Socket CEO Feross Aboukhadijeh joins Risky Business Weekly to unpack recent npm phishing attacks, their limited impact, and the risks if attackers get smarter.