Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update import #916

Merged
merged 2 commits into from
Oct 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions site/docs/es/hosting/cloudflare-workers-nodejs.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ npm install grammy
Edita `src/index.js` o `src/index.ts`, y escribe este código dentro:

```ts
// Ten en cuenta que estamos importando desde 'grammy/web', no desde 'grammy'.
import { Bot, webhookCallback } from "grammy/web";
import { Bot, webhookCallback } from "grammy";

// La siguiente línea de código asume que ha configurado los secretos BOT_TOKEN y BOT_INFO.
// Ver https://developers.cloudflare.com/workers/platform/environment-variables/#secrets-on-deployed-workers.
Expand Down
3 changes: 1 addition & 2 deletions site/docs/hosting/cloudflare-workers-nodejs.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ npm install grammy
Edit `src/index.js` or `src/index.ts`, and write this code inside:

```ts
// Note that we're importing from 'grammy/web', not 'grammy'.
import { Bot, webhookCallback } from "grammy/web";
import { Bot, webhookCallback } from "grammy";

// The following line of code assumes that you have configured the secrets BOT_TOKEN and BOT_INFO.
// See https://developers.cloudflare.com/workers/platform/environment-variables/#secrets-on-deployed-workers.
Expand Down
3 changes: 1 addition & 2 deletions site/docs/id/hosting/cloudflare-workers-nodejs.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ npm install grammy
Tulis kode berikut ke dalam `src/index.js` atau `src/index.ts`:

```ts
// Perhatikan bahwa kita meng-import dari 'grammy/web', bukan 'grammy'.
import { Bot, webhookCallback } from "grammy/web";
import { Bot, webhookCallback } from "grammy";

// Baris kode berikut mengasumsikan bahwa kamu sudah mengonfigurasi secret BOT_TOKEN dan BOT_INFO.
// Lihat https://developers.cloudflare.com/workers/platform/environment-variables/#secrets-on-deployed-workers.
Expand Down
3 changes: 1 addition & 2 deletions site/docs/uk/hosting/cloudflare-workers-nodejs.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ npm install grammy
Відредагуйте `src/index.js` або `src/index.ts` та напишіть такий код всередині:

```ts
// Зверніть увагу, що ми імпортуємо з 'grammy/web', а не з 'grammy'.
import { Bot, webhookCallback } from "grammy/web";
import { Bot, webhookCallback } from "grammy";

// Наступний рядок коду передбачає, що ви налаштували секрети BOT_TOKEN та BOT_INFO.
// Дивіться https://developers.cloudflare.com/workers/platform/environment-variables/#secrets-on-deployed-workers
Expand Down
3 changes: 1 addition & 2 deletions site/docs/zh/hosting/cloudflare-workers-nodejs.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ npm install grammy
编辑 `src/index.js` 或 `src/index.ts`,在里面写下这段代码:

```ts
// 请注意,我们是从 `grammy/web` 而不是 `grammy` 导入。
import { Bot, webhookCallback } from "grammy/web";
import { Bot, webhookCallback } from "grammy";

// 你可以将 `BOT_TOKEN` 替换为你的 bot token,但最好将其存储在环境变量中。
// 更多有关信息,请参阅 https://developers.cloudflare.com/workers/platform/environment-variables/#secrets-on-deployed-workers.
Expand Down
Loading