Skip to content

plugin.json

Every plugin has a plugin.json file at its root. It sets the plugin’s name, version, and entry point, along with other details about the plugin.

{
"name": "sketchbook-shader",
"version": "1.2.0",
"description": "Shaders that give your art an animated sketchbook look",
"author": "Jane Doe <jane@example.com>",
"website": "https://example.com/sketchbook-shader",
"license": "MIT",
"main": "index.js",
"exports": {
"common": ["ui.js"],
"web": ["lines.glsl", "flats.glsl", "highlights.glsl", "shadows.glsl"]
}
}

name is the plugin’s name. Inkweaver uses it to name the bottled .inkb file, and as the prefix for the plugin’s assets.

Your plugin can read its name with getPluginName.

version is the plugin’s version, as a semantic version.

It’s required, and ink bottle won’t package a plugin without a valid one.

description is a one-line summary of what the plugin does.

author says who made the plugin and how to contact them. It uses the same format as npm’s package.json: "Jane Doe <jane@example.com>".

website is the plugin’s web page.

license is the plugin’s license, as an SPDX identifier like MIT or Apache-2.0. You can leave it out if you’re only using the plugin in your own novel.

main is the path to the plugin’s entry point script.

{
"main": "index.js"
}

exports lists the files that keep their original names when Inkweaver builds your novel, grouped by platform.

Inkweaver normally renames each file based on its contents, so list a file here when something outside your plugin needs to find it by name.