Skip to content

Conversation

@sunker
Copy link
Contributor

@sunker sunker commented Oct 24, 2025

What this PR does / why we need it:

Expands the Frontend section of the best practices documentation with guidance on UI styling and theming.

Which issue(s) this PR fixes:

Fixes #2240

Special notes for your reviewer:

@Copilot Copilot AI review requested due to automatic review settings October 24, 2025 08:32
@sunker sunker requested review from a team as code owners October 24, 2025 08:32
@sunker sunker requested review from academo, briangann and s4kh October 24, 2025 08:32
@github-actions
Copy link
Contributor

github-actions bot commented Oct 24, 2025

Hello! 👋 This repository uses Auto for releasing packages using PR labels.

✨ This PR can be merged. It will not be considered when calculating future versions of the npm packages and will not appear in the changelogs.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds best practices documentation for frontend development in Grafana plugins, specifically covering styling and theming guidelines.

Key changes:

  • Adds a new "Frontend" section to the best practices documentation
  • Documents three core frontend development practices: using Grafana UI components, Emotion for styling, and theme variables

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@sunker sunker requested a review from urbiz-grafana October 24, 2025 08:33
@sunker sunker added the no-changelog Don't include in changelog and version calculations label Oct 24, 2025

## Frontend

- **Use Grafana UI components** - Always use components from `@grafana/ui` when building your plugin's user interface. This ensures a consistent UI experience across Grafana and helps prevent UI breakages as Grafana evolves. These components are designed to work seamlessly with Grafana's theming system and follow the [Saga Design System](https://grafana.com/developers/saga/about/overview). For available components, refer to the [Grafana UI documentation](https://developers.grafana.com/ui/latest/index.html?path=/docs/docs-overview-intro--page).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we should be mentioning Saga. @tolzhabayev @sympatheticmoose any thoughts?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No we should not, thanks for raising this @urbiz-grafana. See #2244

Copy link
Contributor

@urbiz-grafana urbiz-grafana left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just one doubt!

@grafana-plugins-platform-bot grafana-plugins-platform-bot bot moved this from 📬 Triage to 🔬 In review in Plugins Platform / Grafana Community Oct 24, 2025
@academo academo merged commit 56412ff into main Oct 24, 2025
24 of 25 checks passed
@academo academo deleted the docs/expand-frontend-best-practices branch October 24, 2025 09:05
@github-project-automation github-project-automation bot moved this from 🔬 In review to 🚀 Shipped in Plugins Platform / Grafana Community Oct 24, 2025
@sunker sunker self-assigned this Oct 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog Don't include in changelog and version calculations

Projects

Status: 🚀 Shipped

Development

Successfully merging this pull request may close these issues.

Docs: clarify usage of global css and non-grafana/ui libraries in plugins

3 participants