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

sumjs-cli

v1.0.5

Published

A futuristic CLI for building React + SumanJS apps

Readme

sumjs

A futuristic CLI for building React + Sumjs apps.

Installation

  1. Build your React application.
  2. Move the assets to the Sumjs resources folder.
  3. Build the Sumjs binary.

Project Structure

const output = await Sumjs.os.execCommand("echo 'Hello World'"); console.log(output.stdOut);


### 2. Filesystem (`Sumjs.filesystem`)
Read and write files on the user's system.

```typescript
// Write a file
await Sumjs.filesystem.writeFile("./my-file.txt", "Hello Sumjs!");

// Read a file
const content = await Sumjs.filesystem.readFile("./my-file.txt");
console.log(content);

// Create a directory
await Sumjs.filesystem.createDirectory("./data");

3. Window Management (Sumjs.window)

Control the application window.

// Minimize window
await Sumjs.window.minimize();

// Toggle fullscreen
if (await Sumjs.window.isFullScreen()) {
    await Sumjs.window.exitFullScreen();
} else {
    await Sumjs.window.setFullScreen();
}

4. Computer Info (Sumjs.computer)

Get system hardware information.

const ram = await Sumjs.computer.getMemoryInfo();
console.log(`Total RAM: ${ram.physical.total} bytes`);

Using in React Components

Since Sumjs is asynchronous, it's best to use it inside useEffect or event handlers.

import { useState } from 'react';

function SystemInfo() {
  const [osInfo, setOsInfo] = useState<string>('');

  const fetchInfo = async () => {
    try {
      const info = await Sumjs.computer.getOSInfo();
      setOsInfo(`${info.name} ${info.version}`);
    } catch (err) {
      console.error("Sumjs API Error:", err);
    }
  };

  return (
    <div>
      <h2>System Info</h2>
      <p>{osInfo}</p>
      <button onClick={fetchInfo}>Get OS Info</button>
    </div>
  );
}

Extensions (Advanced Backend)

If you need to run heavy backend logic (Python, Node.js, Go, etc.) that isn't covered by the native API, you can use Extensions.

  1. Create a folder in extensions/.
  2. Add your backend script (e.g., server.py).
  3. Configure it in sum.config.json.
  4. Communicate using Sumjs.extensions.dispatch and Sumjs.events.on.

sumjs-cli