Набросал меню

This commit is contained in:
2026-01-03 00:14:52 +03:00
parent 2d9b696ef5
commit c0b94c48c7
5 changed files with 41 additions and 5 deletions
+5
View File
@@ -1,11 +1,16 @@
import { Bot } from 'grammy';
import { cmdStart, cmdHelp } from './src/commands';
import { menu } from './src/menu';
const bot = new Bot(process.env.TOKEN);
bot.use(menu);
bot.command('start', cmdStart);
bot.command('help', cmdHelp);
bot.command('menu', async (ctx) => {
await ctx.reply('🛣️ Навигация', { reply_markup: menu });
});
bot.on('message', (ctx) => ctx.reply('Got another message!'));
bot.start();