grafana/packages/grafana-prometheus
Nick Richmond 559fab9dc6
Prometheus: Fuzzy search for metric names in Code Mode (#85396)
* perf: limit metric names in Code Mode suggestions

* feat: configurable metric names limit

* feat: code mode autocomplete info/disclaimer

* chore: put new functionality behind new feature toggle

* refactor: avoid type assertions

* refactor: avoid explicit `any`

refactor: type guards

* refactor: type guards

* chore: add testdata results

* fix: add missing feature toggle guard

* perf: prefer array access to `Array.prototype.at`

* test: add missing config override

* test: refactor for brevity & clarity

* perf: avoid unnecessary mapping

* chore: undo testdata changes

* fix: use correct limit; perf optimizations

* refactor: avoid unnecessary `async`s

* types: simplify

* test: add missing tests

* fix: avoid hardcoding

* test: update mock path

* docs: fix typo

style: remove formatting artifact

style: remove formatting artifact

style: remove formatting artifact

* fix: event scope regression

* style: refactor for clarity

* refactor: prefer `useCallback` to in-effect handler

* refactor: simplify & broaden `filter`

* refactor: rename file to keep with conventions

* chore: mirror Prometheus package changes in app

* refactor: prefer no `@ts-ignore`

* chore: update betterer results

* docs: use type in TSDoc `@link` without `@ts-ignore`

* test: add missing provider

* test: fix jest mock path

* fix: display disclaimer in empty input case
2024-04-04 23:38:23 +03:00
..
src Prometheus: Fuzzy search for metric names in Code Mode (#85396) 2024-04-04 23:38:23 +03:00
CHANGELOG.md Prometheus: Library fixes for using in external vendor DS (#82115) 2024-02-16 12:55:39 -06:00
LICENSE_AGPL Prometheus: Library fixes for using in external vendor DS (#82115) 2024-02-16 12:55:39 -06:00
package.json Update dependency @types/node to v20.12.2 (#85480) 2024-04-02 18:47:56 +03:00
README.md Prometheus: Library fixes for using in external vendor DS (#82115) 2024-02-16 12:55:39 -06:00
rollup.config.ts Prometheus: Library fixes for using in external vendor DS (#82115) 2024-02-16 12:55:39 -06:00
tsconfig.build.json Prometheus: Create Prometheus library (#81641) 2024-02-02 15:30:14 +01:00
tsconfig.json Prometheus: Create Prometheus library (#81641) 2024-02-02 15:30:14 +01:00

Grafana Prometheus Library

@grafana/prometheus is currently in ALPHA.

@grafana/prometheus is a collection of components used to build a Prometheus data source plugin in Grafana.

See package source for more details.

Installation

yarn add @grafana/prometheus

npm install @grafana/prometheus