Skip to content

Commit

Permalink
fix: kaplay() type
Browse files Browse the repository at this point in the history
  • Loading branch information
lajbel committed Oct 24, 2024
1 parent 0ae7758 commit 9561138
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/MonacoEditor/configMonaco.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import docTs from "../../../kaplay/dist/doc.d.ts?raw";
const dataUrlRegex = /data:[^;]+;base64,[A-Za-z0-9+\/]+={0,2}/g;

const globalImport = `
import type { PluginList, MergePlugins, ButtonsDef } from "./types";
import type { PluginList, MergePlugins, ButtonsDef, KAPLAYCtx, KAPLAYOpt } from "types.d.ts";
declare global {
Expand All @@ -15,7 +15,7 @@ const kaplay: <TPlugins extends PluginList<unknown> = [
], TButtons extends ButtonsDef = {}, TButtonsName extends string = keyof TButtons & string>(gopt?: KAPLAYOpt<TPlugins, TButtons>) => TPlugins extends [
undefined
] ? KAPLAYCtx<TButtons, TButtonsName> : KAPLAYCtx<TButtons, TButtonsName> & MergePlugins<TPlugins>;
}
Expand Down

0 comments on commit 9561138

Please sign in to comment.