srclosson / div-panel Goto Github PK
View Code? Open in Web Editor NEWGeneric grafana panel to specify your own html and javascript
License: Apache License 2.0
Generic grafana panel to specify your own html and javascript
License: Apache License 2.0
Can you describe in the Readme how this plugin differs from the other Grafana plugins that permit html/javascript:
text panel
html panel
ajax plugin
ps. Love what you are doing with the OPC-UA plugin. Every automation person is waiting for a solid OPC Grafana plugin wheter they know it or not! ;-)
When attempting a basic panel using the built in grafana queries, chrome starts throwing a bunch of errors. Having issues with any queries or libraries.
Using random walk, 2 errors are thrown as shown in the attached pictures.
Below is JSON
{ "__inputs": [], "__elements": {}, "__requires": [ { "type": "grafana", "id": "grafana", "name": "Grafana", "version": "10.0.3" }, { "type": "panel", "id": "grafana-div-panel", "name": "Div Panel", "version": "1.0.0" } ], "annotations": { "list": [ { "builtIn": 1, "datasource": { "type": "grafana", "uid": "-- Grafana --" }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", "name": "Annotations & Alerts", "type": "dashboard" } ] }, "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, "id": null, "links": [], "liveNow": false, "panels": [ { "datasource": { "type": "grafana", "uid": "grafana" }, "gridPos": { "h": 8, "w": 12, "x": 0, "y": 0 }, "id": 1, "options": { "editor": { "content": "<html>\n<body>\n <div>\n Hello Div Panel\n </div>\n\n <script>\n /**\n * @param elem The div element containing your div panel\n */\n function onDivPanelInit(elem) {\n console.log(\"I am in init\", elem);\n }\n\n /**\n * @param data The data retrieved from your panel data config\n */\n function onDivPanelDataUpdate(data) {\n console.log(\"I have data\", data);\n }\n \n console.log(\"Hello from my script!\");\n </script>\n</body>\n</html>", "editContent": [], "editCss": [] } }, "targets": [ { "datasource": { "type": "datasource", "uid": "grafana" }, "queryType": "randomWalk", "refId": "A" } ], "title": "Panel Title", "type": "grafana-div-panel" } ], "refresh": "", "schemaVersion": 38, "style": "dark", "tags": [], "templating": { "list": [] }, "time": { "from": "now-6h", "to": "now" }, "timepicker": {}, "timezone": "", "title": "Div Panel Data Test", "uid": "aacaf7f9-cfdf-40b1-a490-372d48d58ccb", "version": 5, "weekStart": "" }
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.