@ocpp-debugkit/reporter 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +50 -0
- package/package.json +2 -2
package/README.md
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# @ocpp-debugkit/reporter
|
|
2
|
+
|
|
3
|
+
> Report generators for OCPP DebugKit analysis results.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @ocpp-debugkit/reporter
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
### Generate a Markdown report
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
import { generateMarkdownReport } from '@ocpp-debugkit/reporter';
|
|
17
|
+
import type { AnalysisResult } from '@ocpp-debugkit/reporter';
|
|
18
|
+
|
|
19
|
+
const report = generateMarkdownReport({
|
|
20
|
+
events,
|
|
21
|
+
sessions,
|
|
22
|
+
failures,
|
|
23
|
+
summaries,
|
|
24
|
+
warnings,
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
// report is a Markdown string with:
|
|
28
|
+
// - Session overview table
|
|
29
|
+
// - Timeline summary (action sequences)
|
|
30
|
+
// - Failures (severity, description, suggested steps)
|
|
31
|
+
// - Suggested next steps
|
|
32
|
+
// - Raw event appendix
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Input Type
|
|
36
|
+
|
|
37
|
+
```typescript
|
|
38
|
+
interface AnalysisResult {
|
|
39
|
+
events: Event[];
|
|
40
|
+
sessions: Session[];
|
|
41
|
+
failures: Failure[];
|
|
42
|
+
summaries: SessionSummary[];
|
|
43
|
+
warnings: ParseWarning[];
|
|
44
|
+
metadata?: TraceMetadata;
|
|
45
|
+
}
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
## License
|
|
49
|
+
|
|
50
|
+
Apache 2.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ocpp-debugkit/reporter",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "Report generators (Markdown, HTML) for OCPP DebugKit analysis results.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"url": "https://github.com/ocpp-debugkit/ocpp-debugkit/issues"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@ocpp-debugkit/core": "0.1.
|
|
40
|
+
"@ocpp-debugkit/core": "0.1.1"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"typescript": "^5.7.0",
|