xref: /plugin/bpmnio/README.md (revision a9231c5d78595df1d8f45dcb812adf2776dd6d7c)
1# dokuwiki-plugin-bpmnio
2
3Renders using the bpmn.io js libraries within dokuwiki:
4
5* BPMN v2.0 diagrams
6* DMN v1.3 decision requirement diagrams, decision tables and literal expressions
7
8Refer to this page for details: <https://www.dokuwiki.org/plugin:bpmnio>
9
10## Development
11
12### Prerequisites
13
14* PHP 8.1+
15* [Composer](https://getcomposer.org/)
16* Node.js 20+ and npm
17
18### Setup
19
20```bash
21# Install PHP dev dependencies (phpcs, phpstan)
22composer install
23
24# Install JS/CSS dev dependencies and vendor build packages
25npm install
26```
27
28### Linting
29
30```bash
31# PHP code style
32composer cs
33
34# PHP static analysis
35composer stan
36
37# JavaScript lint
38npm run lint:js
39
40# LESS/CSS lint
41npm run lint:css
42
43# All JS + CSS lints
44npm run lint
45```
46
47### Testing
48
49Tests run within the DokuWiki test framework. Clone the plugin into a DokuWiki
50installation's `lib/plugins/bpmnio/` directory, then run:
51
52```bash
53cd /path/to/dokuwiki
54php vendor/bin/phpunit --group plugin_bpmnio
55```
56
57### Updating vendor libraries
58
59The committed `vendor/` bundles are generated locally from the npm packages
60declared in [package.json](package.json). To update them:
61
62```bash
63# Change the pinned bpmn-js / dmn-js versions in package.json when needed
64npm install
65
66# Rebuild the committed vendor bundles and copied assets
67npm run build:vendor
68
69# Or use the compatibility wrapper
70./update-vendor.sh
71```
72
73The build step emits the production browser bundles into `vendor/`, copies the
74required LESS assets from `node_modules`, and refreshes the public `font/`
75directory used by DokuWiki.
76