
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@cratefit/viz
Advanced tools
Visualization module for @cratefit/pack - 2D Canvas and 3D Three.js rendering for bin packing results.
npm install @cratefit/pack @cratefit/viz
# For 3D rendering, also install three.js
npm install three
import { pack, createBin, createItem } from '@cratefit/pack';
import { renderTopView, renderIsometric } from '@cratefit/viz';
// Pack items
const result = pack({
bins: [createBin({ width: 100, height: 80, depth: 60 })],
items: [createItem({ width: 30, height: 20, depth: 15, quantity: 5 })],
});
// Render to canvas
const canvas = document.getElementById('myCanvas') as HTMLCanvasElement;
renderTopView(canvas, result.packed[0], { showLabels: true });
import { pack } from '@cratefit/pack';
import { create3DScene, renderPackedBin3D, animate } from '@cratefit/viz';
// Create 3D scene
const container = document.getElementById('container');
const { scene, camera, renderer, controls } = await create3DScene(container);
// Render packed bin
await renderPackedBin3D(scene, result.packed[0], { showEdges: true });
// Start animation loop
animate(renderer, scene, camera, controls);
import { createCanvas } from 'canvas'; // npm install canvas
import { renderTopView } from '@cratefit/viz';
import fs from 'fs';
const canvas = createCanvas(800, 600);
renderTopView(canvas, packedBin);
// Export to PNG
const buffer = canvas.toBuffer('image/png');
fs.writeFileSync('output.png', buffer);
renderTopView(canvas, packedBin, options?) - Top-down view (X-Z plane)renderFrontView(canvas, packedBin, options?) - Front view (X-Y plane)renderSideView(canvas, packedBin, options?) - Side view (Z-Y plane)renderIsometric(canvas, packedBin, options?) - Isometric 3D-like viewrenderAllViews(canvas, packedBin, options?) - All views in gridcreate3DScene(container, options?) - Initialize Three.js scenerenderPackedBin3D(scene, packedBin, options?) - Render bin and itemsanimate(renderer, scene, camera, controls) - Start render loopfocusOnBin(camera, controls, bin) - Focus camera on binanimatePacking(scene, packedBin, options?) - Animate packing sequencecreateExplosionView(scene, packedBin, factor) - Exploded viewshowByLayer(scene, layerIndex) - Show specific layertakeScreenshot(renderer, scene, camera) - Capture imageFAQs
Visualization module for CrateFit - 2D Canvas and 3D Three.js rendering
We found that @cratefit/viz demonstrated a healthy version release cadence and project activity because the last version was released less than 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.