Skip to content

Commit

Permalink
Use Entrypoint
Browse files Browse the repository at this point in the history
  • Loading branch information
Shougo committed May 15, 2024
1 parent 64da39d commit 72ca214
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 11 deletions.
14 changes: 11 additions & 3 deletions denops/ddc/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,20 @@ import {
Previewer,
UserOptions,
} from "./types.ts";
import { Denops, ensure, is, Lock, toFileUrl, vars } from "./deps.ts";
import {
Denops,
ensure,
Entrypoint,
is,
Lock,
toFileUrl,
vars,
} from "./deps.ts";
import { Loader } from "./loader.ts";
import { createCallbackContext } from "./callback.ts";
import { getPreviewer, onCompleteDone, onEvent } from "./ext.ts";

export function main(denops: Denops) {
export const main: Entrypoint = (denops: Denops) => {
const loader = new Loader();
const ddc = new Ddc(loader);
const contextBuilder = new ContextBuilder();
Expand Down Expand Up @@ -315,4 +323,4 @@ export function main(denops: Denops) {
}

ddc.initialize(denops);
}
};
19 changes: 11 additions & 8 deletions denops/ddc/deps.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
export type { Denops } from "https://deno.land/x/denops_std@v6.4.2/mod.ts";
export type {
Denops,
Entrypoint,
} from "https://deno.land/x/denops_std@v6.5.0/mod.ts";
export {
echo,
execute,
} from "https://deno.land/x/denops_std@v6.4.2/helper/mod.ts";
} from "https://deno.land/x/denops_std@v6.5.0/helper/mod.ts";
export {
batch,
collect,
} from "https://deno.land/x/denops_std@v6.4.2/batch/mod.ts";
export * as op from "https://deno.land/x/denops_std@v6.4.2/option/mod.ts";
export * as vimOp from "https://deno.land/x/denops_std@v6.4.2/option/vim/mod.ts";
export * as fn from "https://deno.land/x/denops_std@v6.4.2/function/mod.ts";
export * as vars from "https://deno.land/x/denops_std@v6.4.2/variable/mod.ts";
export * as autocmd from "https://deno.land/x/denops_std@v6.4.2/autocmd/mod.ts";
} from "https://deno.land/x/denops_std@v6.5.0/batch/mod.ts";
export * as op from "https://deno.land/x/denops_std@v6.5.0/option/mod.ts";
export * as vimOp from "https://deno.land/x/denops_std@v6.5.0/option/vim/mod.ts";
export * as fn from "https://deno.land/x/denops_std@v6.5.0/function/mod.ts";
export * as vars from "https://deno.land/x/denops_std@v6.5.0/variable/mod.ts";
export * as autocmd from "https://deno.land/x/denops_std@v6.5.0/autocmd/mod.ts";

export * from "jsr:@std/encoding@0.224.0/base64";
export { assertEquals, equal } from "jsr:@std/assert@0.225.1";
Expand Down

0 comments on commit 72ca214

Please sign in to comment.