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

expressionish

v0.1.3

Published

An expression-parsing middle ground library between find-and-replace and full js access

Readme

Expressinish

An expression-parsing middle ground library between find-and-replace and full js access

Installing

npm install --save expressionish

API

You can find the full API documentation at [TODO: add link]

import { evaluate } from 'expressionish';

const variables = new Map();
variables.set('sum', {
    evaluate: async (meta, ...args) => {
        return args.reduce((prev, curr) => prev + Number(curr), 0)
    }
});

await evaluate({
    variables,
    expression: '\$sum[1,2,3]: $sum[1,2,3]'
}) // "$sum[1,2,3]: 6'

Syntax

You can find the full Syntax documentation at [TODO: add link]

Text

Any text that is not seen as having significance is treated as plain text.

Concatenation is done simply by mixing insignificant and significant sequences: v$var is evaluated to "v" followed by result of evaluating $var

Character escapes

Character escapes treat characters that may have potential significance as literl text instead.

  • \\ - backslash
  • \" - quote
  • \$ - dollar sign
  • \[ - opening bracket
  • \, - comma
  • \] - closing brackets
  • \r - carriage return
  • \n - line feed
  • \t - tab

Double-Quoted Text

Text contained with in double quotes is treated as plain-text with the exception of character-escapes(of which get evaluated)

Double Backtick Text

Text contained within double backtick's is treated as plain-text with the exception of Variables

Variables & Lookups

Variables are the power behind expressions. They can take no arguments or a slew of them! An argument can even be an expression of itself, containing variables and the like!

Variables take the format of:

"$" + [<lookup_prefix>] + <name> + [ "[" + <arg> + ["," + <arg>]... + "]" ]

Examples:

$name - variable
$name[1] - variable with one argument
$name[1,2,3] - variable with multiple arguments

$&name - variable lookup
$&name[1] - variable lookup with one argument
$&name[1,2,3] - variable lookup with multiple arguments

When it comes to arguments, leading/trailing whitespace is insignificant

These are all the same
$name[1]
$name[ 1]
$name[ 1 ]
$name[
    1
]