Project: Graylog (Observability and Analysis / Observability)
File: README.md

Graylog Web Plugin Archetype ============================ This module is supposed to help with developing web interface plugins for . It provides classes which help generating a webpack configuration, defining the plugin manifest (metadata as well as entities which are provided to the web interface) as well as the `PluginStore` class which is used for registering plugins to make them accessible for the web interface. This module is supposed to be used in conjunction with the maven archetype which can be found and requires a checkout of the in some place. `npm install --save graylog-web-plugin` ``` $ npm init [...] $ npm --save-dev graylog-web-plugin ``` Create a file named `build.config.js` in your plugin directory, looking like this: ``` module.exports = { websrcpath: '<path to your Graylog git repository>', }; ``` and use a webpack.config.js like this: ``` const PluginWebpackConfig = require('graylog-web-plugin').PluginWebpackConfig; const loadBuildConfig = require('graylog-web-plugin').loadBuildConfig; const path = require('path'); const buildConfig = loadBuildConfig(path.resolve(dirname, './build.config')); module.exports = new PluginWebpackConfig('my.fully.qualified.plugin.classname', buildConfig, { // Here goes your additional webpack configuration. }); ``` The third (optional) parameter for the `PluginWebpackConfig` constructor is an object which is merged into the generated webpack config, so you can add/overwrite any part of the generated configuration. Feel free to contribute to this collection of helpers by forking the repository and submitting a pull request. Thanks! $ npm version [<newversion> | major | minor | patch] $ git push origin master && git push --tags $ npm publish 0.0.21 Add optimizations for production builds. 0.0.20 Add plugin fqdn as prefix of built `module.json`. 0.0.19 Add webpack config to compile typescript code in plugins. 0.0.18 Removing now unneeded shared bundle. 0.0.17 Bugfix, using absolute filename for build config. 0.0.16 Adding build config file including option specifying location of Graylog server repo checkout. 0.0.15 Bugfix, add missing import 0.0.14 Add shared and vendor bundle to generated webpack config 0.0.13 First actually usable version support the JSX language extension. This setting was called `JSX harmony` before, and it is available in one or the other form since IntelliJ 14 and WebStorm 9. Update a single dependency Run `yarn upgrade <package>@<version>` Commit any changes in both `package.json` and `yarn.lock` files Do any changes required to adapt the code to the upgraded modules Update many dependencies It may be dangerous updating many dependencies at the same time, so be sure you checked the upgrade notes of all modules before getting started. Once you are ready to upgrade the modules, Yarn provides a few options to do it: You can pass all packages you want to upgrade to Yarn: `yarn upgrade <package1> <package2>...` Yarn also supports upgrading packages matching a pattern, so you can execute `yarn upgrade --pattern <pattern>` You could execute `yarn upgrade` if you really want to upgrade all packages After doing the upgrade, remember to commit both the `package.json` and `yarn.lock` files