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

doodjs

v0.2.4

Published

A fast and compact client-side JavaScript framework inspired by Vue that adds interactivity to HTML markup via element attributes.

Readme

DoodJS

A simple JavaScript framework to add functionality to your HTML elements.

State

  • The framework is currently in a very early state.

Known issues

Usage

DoodJS can simply be loaded from CDN:

<script src="https://unpkg.com/doodjs"></script>
<script>
  let dood = Dood.init({});
</script>

or as a module:

import { init } from "https://unpkg.com/doodjs?module";
let dood = init({
  yourData: value,
});

Provide a object wich will contain your reactive data available in your HTML elements.

Options

The init function can take a options object as a second argument. The following options are available:

  • root defines the root of DoodJS on the DOM. Standard query selector can be used.
let dood = init({}, { root: "#main" });

Build from source

  • Clone this repository.
  • Run npm install and npm run build.
  • The script is now available in the dist/ directory.

Directives

d-data

Allows to declare a new context. The data will be available on the element the directive is attached to and on all child elements.

<div d-data="{hello: 'world'}">
  <div d-text="hello"></div>
</div>

d-text

Will set the given value as elements innerText.

<div d-text="'Hello, World!'"></div>

d-html

Will set the given value as elements innerHTML.

<div d-html="myHTML"></div>

d-show

Will display the element if given expression is true.

<div d-show="count > 10"></div>

d-model

Will bind the value of the input to the value of the given variable.

<input type="text" d-model="myInput" />

d-for

Will render a list of elements, d-for can contain multiple HTML elements.

<div d-for="item of items">
  <div d-text="item"></div>
</div>

d-for can also itterate over the keys of the given object.

<div d-for="(item,key) of items"
  <div d-text="'Key: '+key"></div>
  <div d-text="'Item: '+item"></div>
</div>

d-if

Will display the element if expression is true. The difference to d-show is that the element will be removed from the DOM if the expression is false.

<div d-if="showMessage">
  <div d-text="message"></div>
</div>

d-on

Will add an event handler with the given function. Modifiers and Arguments are supported.

<button d-on:click="clickHandler">Click me</button>

d-bind

Will bind the given value the specefied property of the element.

<div d-bind:class="class"></div>
<div d-bind:style="{color: error ? 'Red' : 'Green'}"

d-ref

Will add the element to the refs.
Element will be available via $refs.

<div d-ref="tag"></div>
<div d-effect="$refs.tag.innerText = 'Hello, World!'"

d-effect

Will re-run the effect when a value in the expression changes.

<div d-effect="$el.innerText = message"></div>

d-ignore

Elements with the d-ignore directive will be ignored during initialization.

<div d-ignore></div>

inline

Code inside {{/}} brackets will automatically be evaluated and is also reactive.

<div d-data="{message: 'Hello, World!'}"
    <div>Message: {{message}}</div>
</div>

magic variables

There are a list of variables that are available in all directive functions.

  • $el can be used to access the current element.
  • The $refs object can be used to access all elements referenced by d-ref.
  • The $args array contains contains all arguments provided by directive, if any.

Modifiers

Arguments