npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

uv-slicer-wasm

v0.1.0

Published

uv slicer wasm

Readme

UV Slicer WASM

npm version license bundlephobia minzipped size

[!WARNING]
This project is in early development. The API may change before a stable 1.0 release. Use with caution in production.

Overview

This WebAssembly library converts bitmap image data into various resin 3D printer slice formats, optimized for browser-based applications. Similar in functionality to UVTools' converter, this library brings format conversion capabilities directly to web environments.

Key Features

  • 🌐 Browser-first Design: Runs entirely in the browser via WebAssembly
  • 🖼️ Multi-format Support: Convert to/from common resin printing formats
  • SIMD Accelerated: Optimized performance using WebAssembly SIMD
  • 🔄 Parallel Processing: Web Worker support for multi-threaded conversions
  • 🧹 Zero-dependency: Pure C++ compiled to WASM with clean JavaScript interface

Supported Formats

Input Formats

  • Raw bitmap data (Uint8Array)

Output Formats

  • .prz (Phrozen)
  • ...

Installation

NPM

npm install uv-slicer-wasm

Usage

Basic Conversion

import { init } from "uv-slicer-wasm";
import wasmUrl from "uv-slicer-wasm/lib/wasm/uv-slicer.wasm?url";

const wasm = await init(wasmUrl);
const result = wasm.encodePrzImage({ data: data, useColorDiffCompression: useColorDifferenceCompression });

Performance

Typical conversion times on modern browsers:

| Resolution | Format | Single-thread | 4 Workers | SIMD | | -------------- | ------ | ------------- | --------- | ---- | | 8K (7680x4320) | .prz | 300ms | 80ms | 30ms |

API Reference

SliceConverter Class

declare interface EmbindModule {
    encodePwsImage(_0: any): any;
    encodePw0Image(_0: any): any;
    encodePrzImage(_0: any): any;
}

export declare function init(wasmURL: string): Promise<UVSlicerModule>;

export declare type UVSlicerModule = WasmModule & EmbindModule;

declare interface WasmModule {
    _main(_0: number, _1: number): number;
}

export { }

Building from Source

Build Steps

git clone https://github.com/your-repo/uv-slicer-wasm.git
cd uv-slicer-wasm

# Build WASM
mkdir build && cd build
emcmake cmake ..
cmake --build . -j32 --clean-first

# Build JS wrapper
npm install
npm run build

Browser Compatibility

  • Chrome 87+ (with WebAssembly SIMD support recommended)
  • Firefox 83+
  • Edge 89+
  • Safari 14.1+

For best performance, enable WebAssembly SIMD support in your browser flags.

License

MIT License

Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.

Support

For issues or feature requests, please file an issue on our GitHub repository.