Security News
Research
Supply Chain Attack on Rspack npm Packages Injects Cryptojacking Malware
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
canvas-lightning
Advanced tools
Canvas lightning generator.
See the example.
Run command:
npm i canvas-lightning
import canvasLightning from 'canvas-lightning';
const canvasEl = document.querySelector('canvas');
const app = canvasLightning(canvasEl, {
WIDTH: 100,
HEIGHT: 200
});
app.start();
window.addEventListener('resize', start);
/* Cleanup*/
app.stop();
{
/* Minimal deviation from center */
MIN_X: 1,
/* Maximum deviation from center */
MAX_X: 10,
/* Minimum step down */
MIN_Y: 2,
/* Maximum step down */
MAX_Y: 10,
/* Refresh interval. */
LOOP_INTERVAL: 100,
/* Thickness of the lightning. */
LINE_WIDTH: 3,
/* Blur surrounding the line. */
LINE_BLUR: 10,
/* How are the curves rounded? */
LINE_JOIN: 'miter',
/* Color of the lightning */
COLOR_LIGHT: '#fff',
/* Color of the surrounding blur. */
COLOR_BLUR: '#0ff',
/* Background color. */
COLOR_BG: 'transparent',
/* How many images should be cached.
* After filing in the cache, no more renders will be done,
* but existing snapshots will be used. */
CACHE_COUNT: 10,
/* Size of the canvas to be set. */
WIDTH: 2,
HEIGHT: 2
}
FAQs
Canvas lightning generator
We found that canvas-lightning demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.
Security News
Sonar’s acquisition of Tidelift highlights a growing industry shift toward sustainable open source funding, addressing maintainer burnout and critical software dependencies.