/ykl-p01-panel

Primary LanguageTypeScriptApache License 2.0Apache-2.0

Grafana panel plugin template

This template is a starting point for building a panel plugin for Grafana.

What are Grafana panel plugins?

Panel plugins allow you to add new types of visualizations to your dashboard, such as maps, clocks, pie charts, lists, and more.

Use panel plugins when you want to do things like visualize data returned by data source queries, navigate between dashboards, or control external systems (such as smart home devices).

Getting started

Frontend

  1. Install dependencies

    yarn install
  2. Build plugin in development mode or run in watch mode

    yarn dev
    
    # or
    
    yarn watch
  3. Build plugin in production mode

    yarn build
  4. Run the tests (using Jest)

    # Runs the tests and watches for changes
    yarn test
    
    # Exists after running all the tests
    yarn lint:ci
  5. Spin up a Grafana instance and run the plugin inside it (using Docker)

    yarn server
  6. Run the E2E tests (using Cypress)

    # Spin up a Grafana instance first that we tests against 
    yarn server
    
    # Start the tests
    yarn e2e
  7. Run the linter

    yarn lint
    
    # or
    
    yarn lint:fix

Learn more

Below you can find source code for existing app plugins and other related documentation.