
Research
/Security News
Popular Tinycolor npm Package Compromised in Supply Chain Attack Affecting 40+ Packages
Malicious update to @ctrl/tinycolor on npm is part of a supply-chain attack hitting 40+ packages across maintainers
sprotty-vscode-webview
Advanced tools
This library helps you to implement a VS Code webview that displays a Sprotty diagram. You can use sprotty-vscode to integrate such a webview in a VS Code extension.
The diagram itself is implemented with the Sprotty API. See the Sprotty Wiki, the states example and the Sprotty examples for reference.
The next step is to implement a subclass of SprottyStarter
and instantiate it in your entry module as shown below.
export class ExampleSprottyStarter extends SprottyStarter {
createContainer(diagramIdentifier: SprottyDiagramIdentifier) {
return createExampleDiagramContainer(diagramIdentifier.clientId);
}
}
new ExampleSprottyStarter().start();
Don't forget to call the start
method, which initiates the communication to the host extension.
The function createExampleDiagramContainer
should create an InversifyJS container with all necessary Sprotty configuration. The passed clientId
should be used in the baseDiv
and hiddenDiv
ids in Sprotty's ViewerOptions.
In case you are connecting your diagram with a language server, e.g. using Langium, you should use SprottyLspEditStarter
as superclass.
FAQs
Integration of Sprotty in a VS Code extensions (WebView part)
The npm package sprotty-vscode-webview receives a total of 606 weekly downloads. As such, sprotty-vscode-webview popularity was classified as not popular.
We found that sprotty-vscode-webview demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 5 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.
Research
/Security News
Malicious update to @ctrl/tinycolor on npm is part of a supply-chain attack hitting 40+ packages across maintainers
Security News
pnpm's new minimumReleaseAge setting delays package updates to prevent supply chain attacks, with other tools like Taze and NCU following suit.
Security News
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.