Skip to content

Commit 4e3660a

Browse files
committed
Add annotation support
1 parent 87cc85b commit 4e3660a

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

src/datasource.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,11 @@ export class JsonDataSource extends DataSourceApi<JsonApiQuery, JsonApiDataSourc
8888
return frame.fields[0].values.toArray().map((_) => ({ text: _ }));
8989
}
9090

91+
/**
92+
* This line adds support for annotation queries in >=7.2.
93+
*/
94+
annotations = {};
95+
9196
/**
9297
* Checks whether we can connect to the API.
9398
*/

src/plugin.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"id": "marcusolsson-json-datasource",
66
"metrics": true,
77
"logs": true,
8+
"annotations": true,
89
"info": {
910
"description": "A data source plugin for loading JSON APIs into Grafana.",
1011
"author": {

0 commit comments

Comments
 (0)