stampit API
Search…
Installation

Browser usage

For browsers it is recommended to use the stampit module. It's a small (1.5KB gzipped) and browser optimized. Also, it will work in other JavaScript environments and ES5-compatible engines.

NPM

1
npm i -S stampit
Copied!

Bower

1
bower install stampit=https://npmcdn.com/[email protected]
2
bower install stampit=https://unpkg.com/[email protected]
3
bower install stampit=https://cdn.jsdelivr.net/npm/[email protected]
Copied!

Direct script

Use any of the links above. For example:
1
<script src="https://cdn.jsdelivr.net/npm/[email protected]"></script>
Copied!
The above will automatically install stampit to window.stampit.
In a WebWorker or ServiceWorker stampit would install itself to self.stampit.

Compatibility note

The stampit v4 is compatible with any EcmaScript 5 environment, including IE9.
The detailed Release Notes are always available at the GitHub Releases page.

Node.js usage

For node.js it is recommended to use the @stamp/it module. Its source code is more readable than stampit module, so you can easily debug its internals if needed. In addition, it will work in any other ES5-compatible JavaScript environments.
1
npm i -S @stamp/it
Copied!

Compatibility note

The @stamp/it is compatible with any EcmaScript 5 environment, including Node.js v0.1. However, some of the Ecosystem modules are ES6 only.
The release notes can be found on the project page.
Last modified 1yr ago