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

informary

v2.0.23

Published

Informary form data marshaling library.

Readme

Informary

A browser forms data marshalling library that synchronizes HTML form data with JavaScript objects. Provides two-way binding via data-i-* attributes, transaction storage with localStorage, and undo/redo snapshot rings with field-level change detection.

Build Status npm version License: MIT


Features

  • Two-Way Marshalling - Reads form fields into nested JavaScript objects and populates forms from objects, using dot-notation data-i-datum attributes
  • Transaction Storage - Persists form data in browser localStorage keyed by user, context, and GUID for offline use
  • Undo/Redo Snapshots - Circular buffer snapshot rings with configurable depth (default 25 levels)
  • Crash Recovery - Detects unsaved changes from prior sessions and offers detailed diff-based recovery scenarios
  • Field-Level Deltas - Computes detailed diffs between current state and undo/redo buffers, including GUID-level element tracking
  • Array Containers - Supports repeated form sections via data-i-container and data-i-index attributes
  • Non-HTML State - Stores programmatic state that gets merged into the marshalled record object without requiring DOM elements
  • Browser Compatible - Builds for modern browsers and legacy environments (including wkhtmltopdf)

Installation

npm install informary

Quick Start

<input type="text" data-i-form="MyForm" data-i-datum="Name.First" value="">
<input type="text" data-i-form="MyForm" data-i-datum="Name.Last" value="">
const Informary = require('informary');

let informary = new Informary({ Form: 'MyForm', jQuery: jQuery });

// Populate the form from a data object
informary.marshalDataToForm({ Name: { First: 'Steven', Last: 'Velozo' } }, () => {});

// Read the form back into an object
let record = {};
informary.marshalFormToData(record, () =>
{
    console.log(record.Name.First); // "Steven"
});

How It Works

Informary uses HTML data-i-* attributes to map form elements to paths in a JavaScript object tree. The data-i-form attribute identifies which form an element belongs to, and data-i-datum provides the dot-notation path into the data object.

Usage Lifecycle

Data Attributes

| Attribute | Required | Description | |-----------|----------|-------------| | data-i-form | Yes | Form identifier matching Settings.Form | | data-i-datum | Yes | Dot-notation path to the property (e.g. Header.Location.Station) | | data-i-container | No | Array container path for repeated sections | | data-i-index | No | Array index within the container | | data-i-guid | No | Unique identifier for tracking element additions/deletions |

Documentation

Full documentation is available in the docs folder:

Part of the Retold Framework

Informary is designed to work with other Pict packages for building form-driven applications:

Testing

Run the test suite:

npm test

Run with coverage:

npm run coverage

Building

Build for modern browsers:

npm run build

Build for legacy browser compatibility:

npm run build-compatible

Related Packages

  • pict - MVC application framework
  • cachetrax - Caching service
  • fable - Application services framework

License

MIT

Contributing

Pull requests are welcome. For details on our code of conduct, contribution process, and testing requirements, see the Retold Contributing Guide.