[v10.0.x] Docs: Plugin doc review changes from chunk 1-B with corrected set of files (#68149)
Docs: Plugin doc review changes from chunk 1-B with corrected set of files (#67164)
* Re-pushing doc review changes from 1-B with fewer files
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Fix for URL examples
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Data frames fixes
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Fixes from doc review
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* More doc review changes
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Doc fixes
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Doc fix
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Prettier
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Fix migration index
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Fix screenshot
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Doc fixes
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
* Quick fix
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
---------
Signed-off-by: Joe Perez <joseph.perez@grafana.com>
(cherry picked from commit d6ba522c3c)
Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
This commit is contained in:
co-authored by
Joseph Perez
parent
d2f74c4942
commit
c4ec980527
@@ -1,10 +1,10 @@
|
||||
---
|
||||
title: Error handling
|
||||
title: Work with error handling
|
||||
---
|
||||
|
||||
# Error handling
|
||||
# Work with error handling
|
||||
|
||||
This guide explains how to handle errors in plugins.
|
||||
This guide explains how to handle errors in plugins and provides suggestions for common scenarios.
|
||||
|
||||
## Provide usable defaults
|
||||
|
||||
@@ -33,7 +33,7 @@ Grafana displays the error message in the top-left corner of the panel.
|
||||
|
||||
{{< figure src="/static/img/docs/panel_error.png" class="docs-image--no-shadow" max-width="850px" >}}
|
||||
|
||||
Avoid displaying overly-technical error messages to the user. If you want to let technical users report an error, consider logging it instead.
|
||||
We recommend that you avoid displaying overly technical error messages to the user. If you want to let technical users report an error, consider logging it to the console instead.
|
||||
|
||||
```ts
|
||||
try {
|
||||
@@ -44,7 +44,9 @@ try {
|
||||
}
|
||||
```
|
||||
|
||||
> **Note:** Grafana displays the exception message in the UI as written, so we recommend using grammatically correct sentences. For more information, refer to the [Documentation style guide](https://github.com/grafana/grafana/blob/main/contribute/style-guides/documentation-style-guide.md).
|
||||
> **Note:** Grafana displays the exception message in the UI as written, so use grammatically correct sentences. For more information, refer to the [Documentation style guide](https://github.com/grafana/grafana/blob/main/contribute/style-guides/documentation-style-guide.md).
|
||||
|
||||
## Common error scenarios
|
||||
|
||||
Here are some examples of situations where you might want to display an error to the user.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user