jetpack-id

Creates an ID from a Firefox Jetpack manifest

MPL 2.0 5 个版本
安装
npm install jetpack-id
yarn add jetpack-id
pnpm add jetpack-id
bun add jetpack-id
README

jetpack-id Build Status

Takes a Jetpack addon manifest object and returns a properly formatted ID for the addon. Works with cfx and jpm and any Jetpack addon that uses a package.json.

Usage

var getID = require("jetpack-id");

getID({ name: "my-addon" }); // "@my-addon"
getID({ id: "tab-fixer@addon" }); // "tab-fixer@addon"

// Manifest's generated by cfx generate an ID that is invalid -- this
// should be manually changed to be compatable with AMO by appending
// a `@jetpack` at the end, and this module does NOT do that.
getID({ id: "jid1-JtUwP0fsy08AKw" }); // null

Installing

  • npm install jetpack-id

License

MPL 2.0 License, copyright (c) 2014 Jordan Santell

版本列表
1.0.0 2015-04-09
0.0.4 2014-07-08
0.0.3 2014-07-08
0.0.2 2014-03-21
0.0.1 2014-02-12