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 🙏

© 2026 – Pkg Stats / Ryan Hefner

sourcemap-decoder

v1.0.2

Published

Node binding for https://github.com/getsentry/rust-sourcemap

Readme

Sourcemap Decoder

rust-sourcemap nodejs bindings

Install

Make sure you have rust installed in your environment. follow this link: https://www.rust-lang.org/en-US/install.html to install rust toolchains.

如果你是中国用户,可以使用 curl https://sh.rustup.rs -sSf | sed "s/https:\/\/static.rust-lang.org\/rustup\/dist/https:\/\/mirrors.ustc.edu.cn\/rust-static\/rustup\/dist/g" | sh 来安装

run yarn add sourcemap-decoder or npm i sourcemap-decoder to install

如果你是中国用户,在执行安装命令之前可以先执行(复制多行,粘贴到命令行,回车):

cat > $HOME/.cargo/config << EOF
[source.crates-io]
registry = "https://github.com/rust-lang/crates.io-index"
replace-with = 'ustc'
[source.ustc]
registry = "git://mirrors.ustc.edu.cn/crates.io-index"
EOF

Working in Docker

There is a Official rust Dockerfile in Github. You can follow this file to setup your Dockerfile.

如果你是中国用户,Dockerfile 是一份 Dockerfile 的样板文件,它可以在国内达到更快的 Build 速度

If you want to use neon bindings with your NodeJS project in Docker, I suggest you don't install rust toolchains in your production use Docker Image, just install them in your ci environment, and run yarn install --production or npm install --production, then use Docker ADD command to copy all your files into your production Docker Image. And if you do that, don't forget to keep your NodeJS version in ci environment to be the same with the NodeJS version in production environment.

如果你需要在生产环境里面使用 neon bindings 相关的项目,建议 不要production 使用的 Docker Image 内安装 Rust 相关的工具链,这样会极大增加 Docker Image 的体积,你可以在你的 ci 环境内安装 Rust 相关的工具,在执行 yarn install --production 或者 npm install --production 后将所有文件 ADD 到生产环境的 Docker Image 中。如果你这样做,确保 ci 运行时的 NodeJS 版本与 production 环境的 NodeJS 版本一致。

Benchmark

run: yarn benchmark or npm run benchmark to see the benchmark result.

This is the benchmark result in my machine:

Hardware info:

ProductName:    Mac OS X
ProductVersion: 10.13.3
BuildVersion:   17D47
Model Name: MacBook Pro
Model Identifier: MacBookPro14,2
Processor Name: Intel Core i5
Processor Speed: 3.1 GHz
Number of Processors: 1
Total Number of Cores: 2
L2 Cache (per Core): 256 KB
L3 Cache: 4 MB
Memory: 16 GB
$ node benchmark
JavaScript parse time 50794 microseconds
Rust parse time: 39 microseconds
JavaScript parse result, Source: webpack:///src/utils/logger/logger.ts, Line: 56
Rust parse result, Source: webpack:///./src/utils/logger/logger.ts, Line: 56
✨  Done in 0.33s.