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

@pyscript/bridge

v0.2.2

Published

A JS based way to use PyScript modules

Readme

@pyscript/bridge

Import Python utilities directly in JS

// main thread
const { ffi: { func_a, func_b } } = await import('./test.js');

// test.js
import bridge from 'https://esm.run/@pyscript/bridge';
export const ffi = bridge(import.meta.url, { type: 'mpy', worker: false });

// test.py
def func_a(value):
    print(f"hello {value}")

def func_b():
    import sys
    return sys.version

Options

  • pyscript: the release version to automatically import if not already available on the page. If no version is provided the developers' channel version will be used instead (for developers' purposes only).
  • type: py by default to bootstrap Pyodide.
  • worker: true by default to bootstrap in a Web Worker.
  • config: either a string or a PyScript compatible config JS literal to make it possible to bootstrap files and whatnot. If specified, the worker becomes implicitly true to avoid multiple configs conflicting on the main thread.
  • env: to share the same environment across multiple modules loaded at different times.

Tests

Run npx mini-coi . within this folder to then reach out http://localhost:8080/test/ that will show:

PyScript Bridge
------------------
no config

The test.js files uses the following defaults:

  • pyscript as "2025.8.1"
  • type as "mpy"
  • worker as false
  • config as undefined
  • env as undefined

To test any variant use query string parameters so that ?type=py will use py instead, worker will use a worker and config will use a basic config that brings in another file from the same folder which exposes the version.

To recap: http://localhost:8080/test/?type=py&worker&config will show this instead:

PyScript Bridge
------------------
3.12.7 (main, May 15 2025, 18:47:24) ...

Please note when a config is used, the worker attribute is always true.