
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
three-sketch
Advanced tools
The sketch emits update
, resize
, and mousemove
events at the times you
would expect. Most of the time, the default render/resize/mousemove event
handlers will do everything you need. If you need to do something in addition,
you can use the events to create side effects. If you need to do something
completely different, you can overwrite some of the key handlers:
sketch.on('update', delta => {
camera.rotation.y = sketch.time * 0.0001 % 360;
});
sketch.render = function (delta) {
// The default render loop doesn't render to a texture. But now it will!
sketch.renderer.render(sketch.scene, sketch.camera, someRenderTarget);
}
import { Sketch } from '../src';
import { BoxBufferGeometry, MeshBasicMaterial, Mesh } from 'three';
window.onload = function () {
const sketch = Sketch();
document.body.appendChild(sketch.canvas);
const geo = new BoxBufferGeometry(1, 1, 1);
const mat = new MeshBasicMaterial({ color: 0xff0000 });
const box = new Mesh(geo, mat);
sketch.scene.add(box);
sketch.camera.fov = 60;
sketch.camera.position.z = 5;
sketch.camera.updateProjectionMatrix();
sketch.on('update', delta => {
box.rotation.x = sketch.time * 0.0001 % 360;
box.rotation.y = sketch.time * 0.0002 % 360;
});
sketch.on('resize', size => {
// three-sketch takes care of everything
});
sketch.on('mousemove', mouse => {
// mouse coorodinates are in range [-1, 1]
sketch.camera.position.x = mouse.x;
sketch.camera.position.y = mouse.y;
sketch.camera.lookAt(box.position);
});
sketch.start();
};
FAQs
a batteries-included three.js starter pack
The npm package three-sketch receives a total of 0 weekly downloads. As such, three-sketch popularity was classified as not popular.
We found that three-sketch 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
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.