diff --git a/examples/bot.tsx b/examples/bot.tsx index e455c3d..7f757ad 100644 --- a/examples/bot.tsx +++ b/examples/bot.tsx @@ -1,5 +1,4 @@ -// deno-lint-ignore-file no-import-prefix -- grammy pulled directly from denopkg in the example -import { Bot } from "https://denopkg.com/grammyjs/grammY@v1.45.1/src/mod.ts"; +import { Bot } from "../src/deps.deno.ts"; import { Bold, Divider, diff --git a/package.json b/package.json index a4a07e3..b967c16 100644 --- a/package.json +++ b/package.json @@ -28,10 +28,12 @@ }, "files": ["out"], "scripts": { - "build": "deno2node --project tsconfig.json" + "build": "deno2node --project tsconfig.json", + "prepare": "npm run build" }, "devDependencies": { - "deno2node": "^6.0.0" + "deno2node": "^6.0.0", + "grammy": "^1.45.1" }, "keywords": [ "telegram", diff --git a/src/deps.deno.ts b/src/deps.deno.ts index 3d3f4eb..1164dc1 100644 --- a/src/deps.deno.ts +++ b/src/deps.deno.ts @@ -1,7 +1,8 @@ -export type { - Context, - InputFile, - NextFunction, +export { + Bot, + type Context, + type InputFile, + type NextFunction, } from "https://denopkg.com/grammyjs/grammY@v1.45.1/src/mod.ts"; export type { InputMediaAnimation, diff --git a/src/deps.node.ts b/src/deps.node.ts index e8448da..485e3fb 100644 --- a/src/deps.node.ts +++ b/src/deps.node.ts @@ -1,4 +1,4 @@ -export type { Context, InputFile, NextFunction } from "grammy"; +export { Bot, type Context, type InputFile, type NextFunction } from "grammy"; export type { InputMediaAnimation, InputMediaAudio,