diff --git a/public/app/core/utils/richHistory.ts b/public/app/core/utils/richHistory.ts index d02b886d19a..b99a16f5ceb 100644 --- a/public/app/core/utils/richHistory.ts +++ b/public/app/core/utils/richHistory.ts @@ -26,7 +26,7 @@ import { SortOrder, } from './richHistoryTypes'; -export { RichHistorySearchFilters, RichHistorySettings, SortOrder }; +export { type RichHistorySearchFilters, type RichHistorySettings, SortOrder }; /* * Add queries to rich history. Save only queries within the retention period, or that are starred. diff --git a/public/app/features/dashboard-scene/settings/version-history/index.ts b/public/app/features/dashboard-scene/settings/version-history/index.ts index c87d2d0b9b7..880541e40d2 100644 --- a/public/app/features/dashboard-scene/settings/version-history/index.ts +++ b/public/app/features/dashboard-scene/settings/version-history/index.ts @@ -1,4 +1,4 @@ -export { HistorySrv, historySrv, RevisionsModel } from './HistorySrv'; +export { HistorySrv, historySrv, type RevisionsModel } from './HistorySrv'; export { VersionHistoryTable } from './VersionHistoryTable'; export { VersionHistoryHeader } from './VersionHistoryHeader'; export { VersionsHistoryButtons } from './VersionHistoryButtons'; diff --git a/public/app/features/explore/TraceView/components/types/index.tsx b/public/app/features/explore/TraceView/components/types/index.tsx index 0d8c47117b1..e91e53e601b 100644 --- a/public/app/features/explore/TraceView/components/types/index.tsx +++ b/public/app/features/explore/TraceView/components/types/index.tsx @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -export { TraceSpan, TraceResponse, Trace, TraceProcess, TraceLink, CriticalPathSection } from './trace'; -export { SpanBarOptions, SpanBarOptionsData } from '../settings/SpanBarSettings'; -export { default as TTraceTimeline } from './TTraceTimeline'; -export { default as TNil } from './TNil'; -export { SpanLinkFunc, SpanLinkDef } from './links'; +export type { TraceSpan, TraceResponse, Trace, TraceProcess, TraceLink, CriticalPathSection } from './trace'; +export type { SpanBarOptions, SpanBarOptionsData } from '../settings/SpanBarSettings'; +export type { default as TTraceTimeline } from './TTraceTimeline'; +export type { default as TNil } from './TNil'; +export type { SpanLinkFunc, SpanLinkDef } from './links'; diff --git a/public/app/features/variables/types.ts b/public/app/features/variables/types.ts index c25dacb0459..ede3b842552 100644 --- a/public/app/features/variables/types.ts +++ b/public/app/features/variables/types.ts @@ -10,7 +10,7 @@ import { VariableHide, TypedVariableModel, } from '@grafana/data'; -export { BaseVariableModel as VariableModel } from '@grafana/data'; +export type { BaseVariableModel as VariableModel } from '@grafana/data'; import { TemplateSrv } from '@grafana/runtime'; import { NEW_VARIABLE_ID } from './constants'; diff --git a/public/app/plugins/datasource/azuremonitor/types/templateVariables.ts b/public/app/plugins/datasource/azuremonitor/types/templateVariables.ts index 10b6123564e..467a8d3a3c9 100644 --- a/public/app/plugins/datasource/azuremonitor/types/templateVariables.ts +++ b/public/app/plugins/datasource/azuremonitor/types/templateVariables.ts @@ -1,4 +1,4 @@ -export { +export type { GrafanaTemplateVariableQueryType, UnknownQuery, AppInsightsMetricNameQuery, diff --git a/public/app/plugins/datasource/cloudwatch/expressions.ts b/public/app/plugins/datasource/cloudwatch/expressions.ts index a7dce622813..206e9284089 100644 --- a/public/app/plugins/datasource/cloudwatch/expressions.ts +++ b/public/app/plugins/datasource/cloudwatch/expressions.ts @@ -5,14 +5,14 @@ import { } from './dataquery.gen'; export { QueryEditorPropertyType, - QueryEditorProperty, - QueryEditorPropertyExpression, - QueryEditorGroupByExpression, - QueryEditorFunctionExpression, - QueryEditorFunctionParameterExpression, - QueryEditorArrayExpression, + type QueryEditorProperty, + type QueryEditorPropertyExpression, + type QueryEditorGroupByExpression, + type QueryEditorFunctionExpression, + type QueryEditorFunctionParameterExpression, + type QueryEditorArrayExpression, QueryEditorExpressionType, - QueryEditorExpression, + type QueryEditorExpression, } from './dataquery.gen'; export interface QueryEditorOperator extends QueryEditorOperatorBase { diff --git a/public/app/plugins/datasource/elasticsearch/types.ts b/public/app/plugins/datasource/elasticsearch/types.ts index d8d97308882..635fa81e2c7 100644 --- a/public/app/plugins/datasource/elasticsearch/types.ts +++ b/public/app/plugins/datasource/elasticsearch/types.ts @@ -19,7 +19,7 @@ import { } from './dataquery.gen'; export * from './dataquery.gen'; -export { ElasticsearchDataQuery as ElasticsearchQuery } from './dataquery.gen'; +export type { ElasticsearchDataQuery as ElasticsearchQuery } from './dataquery.gen'; // We want to extend the settings of the Logs query with additional properties that // are not part of the schema. This is a workaround, because exporting LogsSettings diff --git a/public/app/plugins/datasource/jaeger/_importedDependencies/types/index.tsx b/public/app/plugins/datasource/jaeger/_importedDependencies/types/index.tsx index 990c2e506b0..f777aee8566 100644 --- a/public/app/plugins/datasource/jaeger/_importedDependencies/types/index.tsx +++ b/public/app/plugins/datasource/jaeger/_importedDependencies/types/index.tsx @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -export { TraceSpan, TraceResponse, Trace, TraceProcess, TraceLink, CriticalPathSection } from './trace'; +export type { TraceSpan, TraceResponse, Trace, TraceProcess, TraceLink, CriticalPathSection } from './trace'; diff --git a/public/app/plugins/datasource/loki/querybuilder/types.ts b/public/app/plugins/datasource/loki/querybuilder/types.ts index c6631fcf164..055edb20dc8 100644 --- a/public/app/plugins/datasource/loki/querybuilder/types.ts +++ b/public/app/plugins/datasource/loki/querybuilder/types.ts @@ -33,7 +33,7 @@ export enum LokiVisualQueryOperationCategory { Formats = 'Formats', LineFilters = 'Line filters', LabelFilters = 'Label filters', - BinaryOps = BINARY_OPERATIONS_KEY, + BinaryOps = `${BINARY_OPERATIONS_KEY}`, } export enum LokiOperationId { diff --git a/public/app/plugins/panel/candlestick/types.ts b/public/app/plugins/panel/candlestick/types.ts index adf699253c8..b4754cd6394 100644 --- a/public/app/plugins/panel/candlestick/types.ts +++ b/public/app/plugins/panel/candlestick/types.ts @@ -28,12 +28,12 @@ export const defaultOptions: Partial = { }; export { - Options, - CandlestickColors, + type Options, + type CandlestickColors, defaultCandlestickColors, CandleStyle, ColorStrategy, VizDisplayMode, - CandlestickFieldMap, - FieldConfig, + type CandlestickFieldMap, + type FieldConfig, }; diff --git a/public/app/plugins/panel/geomap/types.ts b/public/app/plugins/panel/geomap/types.ts index 30d031aa9d3..22804bc6b29 100644 --- a/public/app/plugins/panel/geomap/types.ts +++ b/public/app/plugins/panel/geomap/types.ts @@ -53,4 +53,10 @@ export interface MapLayerState extends LayerElement { mouseEvents: Subject; } -export { Options, MapViewConfig, TooltipOptions, TooltipMode, defaultMapViewConfig } from './panelcfg.gen'; +export { + type Options, + type MapViewConfig, + type TooltipOptions, + TooltipMode, + defaultMapViewConfig, +} from './panelcfg.gen'; diff --git a/public/app/plugins/panel/logs/types.ts b/public/app/plugins/panel/logs/types.ts index 4f4c62f722f..8225ca925f4 100644 --- a/public/app/plugins/panel/logs/types.ts +++ b/public/app/plugins/panel/logs/types.ts @@ -2,7 +2,7 @@ import React, { ReactNode } from 'react'; import { DataFrame } from '@grafana/data'; -export { Options } from './panelcfg.gen'; +export type { Options } from './panelcfg.gen'; type onClickFilterLabelType = (key: string, value: string, frame?: DataFrame) => void; type onClickFilterOutLabelType = (key: string, value: string, frame?: DataFrame) => void; diff --git a/public/app/plugins/panel/nodeGraph/types.ts b/public/app/plugins/panel/nodeGraph/types.ts index 39412bbde63..59b7e03b367 100644 --- a/public/app/plugins/panel/nodeGraph/types.ts +++ b/public/app/plugins/panel/nodeGraph/types.ts @@ -2,7 +2,7 @@ import { SimulationNodeDatum, SimulationLinkDatum } from 'd3-force'; import { DataFrame, Field, IconName } from '@grafana/data'; -export { Options as NodeGraphOptions, ArcOption } from './panelcfg.gen'; +export type { Options as NodeGraphOptions, ArcOption } from './panelcfg.gen'; export type NodeDatum = SimulationNodeDatum & { id: string; diff --git a/tsconfig.json b/tsconfig.json index ce0dff499c2..c24104df189 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -9,6 +9,7 @@ "resolveJsonModule": true, "useUnknownInCatchVariables": true, "incremental": true, + "isolatedModules": true, "tsBuildInfoFile": "./tsconfig.tsbuildinfo", "paths": { "@grafana/schema/dist/esm/*": ["../packages/grafana-schema/src/*"]