mirror of
https://github.com/apache/superset.git
synced 2026-04-19 08:04:53 +00:00
chore: TypeScript Configuration Modernization and Cleanup (#35159)
This commit is contained in:
committed by
GitHub
parent
a889ae75fc
commit
6cb3ef9f5d
@@ -30,6 +30,7 @@
|
||||
"lodash": "^4.17.21"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@apache-superset/core": "*",
|
||||
"@superset-ui/chart-controls": "*",
|
||||
"@superset-ui/core": "*",
|
||||
"echarts": "*",
|
||||
|
||||
@@ -16,8 +16,6 @@
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import dayjs from 'dayjs';
|
||||
import utc from 'dayjs/plugin/utc';
|
||||
import { Metric } from '@superset-ui/chart-controls';
|
||||
import {
|
||||
ChartProps,
|
||||
@@ -27,6 +25,8 @@ import {
|
||||
SimpleAdhocFilter,
|
||||
ensureIsArray,
|
||||
} from '@superset-ui/core';
|
||||
import { extendedDayjs as dayjs } from '@superset-ui/core/utils/dates';
|
||||
import 'dayjs/plugin/utc';
|
||||
import {
|
||||
getComparisonFontSize,
|
||||
getHeaderFontSize,
|
||||
@@ -35,8 +35,6 @@ import {
|
||||
|
||||
import { getOriginalLabel } from '../utils';
|
||||
|
||||
dayjs.extend(utc);
|
||||
|
||||
export const parseMetricValue = (metricValue: number | string | null) => {
|
||||
if (typeof metricValue === 'string') {
|
||||
const dateObject = dayjs.utc(metricValue, undefined, true);
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
import dayjs from 'dayjs';
|
||||
import utc from 'dayjs/plugin/utc';
|
||||
import {
|
||||
getTimeFormatter,
|
||||
@@ -29,6 +28,7 @@ import {
|
||||
SMART_DATE_ID,
|
||||
TimeGranularity,
|
||||
} from '@superset-ui/core';
|
||||
import { extendedDayjs as dayjs } from '@superset-ui/core/utils/dates';
|
||||
|
||||
dayjs.extend(utc);
|
||||
|
||||
|
||||
@@ -33,8 +33,8 @@ import {
|
||||
t,
|
||||
tooltipHtml,
|
||||
} from '@superset-ui/core';
|
||||
import { extendedDayjs as dayjs } from '@superset-ui/core/utils/dates';
|
||||
import { CallbackDataParams } from 'echarts/types/src/util/types';
|
||||
import dayjs from 'dayjs';
|
||||
import {
|
||||
Cartesian2dCoordSys,
|
||||
EchartsGanttChartProps,
|
||||
|
||||
@@ -23,8 +23,7 @@ import {
|
||||
SqlaFormData,
|
||||
supersetTheme,
|
||||
} from '@superset-ui/core';
|
||||
import { EchartsBubbleChartProps } from 'plugins/plugin-chart-echarts/src/Bubble/types';
|
||||
|
||||
import { EchartsBubbleChartProps } from '../../src/Bubble/types';
|
||||
import transformProps, { formatTooltip } from '../../src/Bubble/transformProps';
|
||||
|
||||
const defaultFormData: SqlaFormData = {
|
||||
|
||||
@@ -2,21 +2,8 @@
|
||||
"compilerOptions": {
|
||||
"composite": false,
|
||||
"emitDeclarationOnly": false,
|
||||
"noEmit": true,
|
||||
"rootDir": "."
|
||||
},
|
||||
"extends": "../../../tsconfig.json",
|
||||
"include": [
|
||||
"**/*",
|
||||
"../types/**/*",
|
||||
"../../../types/**/*"
|
||||
],
|
||||
"references": [
|
||||
{
|
||||
"path": "../../../packages/superset-ui-chart-controls"
|
||||
},
|
||||
{
|
||||
"path": "../../../packages/superset-ui-core"
|
||||
}
|
||||
]
|
||||
"include": ["**/*", "../types/**/*", "../../../types/**/*"]
|
||||
}
|
||||
|
||||
@@ -1,17 +1,18 @@
|
||||
{
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"extends": "../../tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
"outDir": "lib",
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"@superset-ui/core/components": ["../../packages/superset-ui-core/src/components"]
|
||||
}
|
||||
"baseUrl": "../..",
|
||||
"outDir": "lib"
|
||||
},
|
||||
"include": ["src/**/*", "types/**/*"],
|
||||
"exclude": ["lib", "test"],
|
||||
"include": ["src/**/*.ts", "src/**/*.tsx", "types/**/*"],
|
||||
"exclude": [
|
||||
"src/**/*.js",
|
||||
"src/**/*.jsx",
|
||||
"src/**/*.test.*",
|
||||
"src/**/*.stories.*"
|
||||
],
|
||||
"references": [
|
||||
{ "path": "../../packages/superset-core" },
|
||||
{ "path": "../../packages/superset-ui-core" },
|
||||
{ "path": "../../packages/superset-ui-chart-controls" }
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user