A plugin is a folder on the SD card. You never rebuild firmware. Copy the folder onto the card and the reader finds it.
/plugins/my-plugin/
+-- manifest.json <- name, version, where the web UI shows it (optional)
+-- plugin.js <- JavaScript that runs in your BROWSER (optional)
+-- device.json <- declarative catalog/events that run ON THE READER (optional)
+-- README.md <- help text shown on the reader (optional)
+-- ...anything else (icons, config.json, token.json, extra JS)
A folder counts as a plugin if it has at least one of manifest.json, plugin.js or device.json.