Skip to content

Commit

Permalink
fix(types): export ChartOptions from RuntimeOptions (#5475)
Browse files Browse the repository at this point in the history
  • Loading branch information
xcy960815 authored Aug 29, 2023
1 parent 040767d commit 73ded25
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions src/api/chart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ import { G2Spec } from '../spec';
import { extend, API } from './extend';
import { library } from './library';
import { Runtime } from './runtime';
import type { RuntimeOptions } from './runtime';

export interface Chart extends API<G2Spec, typeof library> {}

export const Chart = extend(Runtime, library);

export type ChartOptions = Omit<RuntimeOptions, 'lib'>;
2 changes: 1 addition & 1 deletion src/api/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export { Chart } from './chart';
export { Chart, type ChartOptions } from './chart';
export { MarkNode } from './mark';
export { CompositionNode } from './composition';
export { register } from './library';
Expand Down

0 comments on commit 73ded25

Please sign in to comment.