This is the Firefox App manifest validator for verifying that your manifest.webapp
file has the correct information before submitting to the Firefox Marketplace.
git clone git@github.com:mozilla/node-firefox-app-validator-manifest.git
cd node-firefox-app-validator-manifest
npm install
var fs = require('fs');
var Manifest = require('firefox-app-validator-manifest');
var ff = new Manifest();
fs.readFile('manifest.webapp', 'utf8', function (err, data) {
if (!err) {
var results = ff.validate(data, options);
// If there are any errors or warnings, this will have them listed.
console.log(results);
}
});
The first parameter to the validate()
method expects a webapp manifest. The
second parameter, however, can be an object containing validation options.
These options include:
-
listed
- defaultfalse
, flag whether or not this app will be listed on the Marketplace -
packaged
- defaultfalse
, flag whether or not this app is packaged, rather than a plain web app
# To run tests once
npm test
# To run tests continually on file change
npm run-script testwatch
Mozilla Public License Version 2.0