Move Grafana tutorials from grafana/tutorials repository (#62309)
* Add Grafana tutorials originally from tutorials repository
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
* Replace tutorials/step shortcode with ordinary headings
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
* Fix typos reported by codespell
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
* Fix doc-validator linting and run prettier
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
* Specify version in tutorials lookup as non-rendered pages do not have a relative permalink used to infer the version
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
* Use latest version
Ensures CI passes and only breaks one website build as the backport to
v9.3.x will solve the missing "latest" pages on publishing.
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
---------
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 4563111180)
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
1.1 KiB
Executable File
title
| title |
|---|
| Create Plugin |
Tooling for modern web development can be tricky to wrap your head around. While you certainly can write your own webpack configuration, for this guide, you'll be using grafana create-plugin tool
Grafana create-plugin tool is a CLI application that simplifies Grafana plugin development, so that you can focus on code. The tool scaffolds a starter plugin and all the required configuration for you.
-
In the plugin directory, create a plugin from template using create-plugin:
npx @grafana/create-plugin -
Change directory to your newly created plugin:
cd my-plugin -
Install the dependencies:
yarn install -
Build the plugin:
yarn dev -
Restart the Grafana server for Grafana to discover your plugin.
-
Open Grafana and go to Configuration -> Plugins. Make sure that your plugin is there.
By default, Grafana logs whenever it discovers a plugin:
INFO[01-01|12:00:00] Registering plugin logger=plugins name=my-plugin