From 8f35dfd03909b0a286a47f1313817342efdb4d23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9F=9A=E5=AD=90Youzi?= <93034834+Youzi9601@users.noreply.github.com> Date: Sun, 20 Apr 2025 22:10:24 +0800 Subject: [PATCH] docs(readme): add import statement for pure REST usage to align with other examples (#10838) * docs(readme): add import statement for pure REST usage to align with other examples Added missing `import` statements in the "Independent REST API Usage" section to maintain consistency with the rest of the README examples. This change also ensures that the usage of `@discordjs/core` reflects a REST-only setup by importing from `@discordjs/core/http-only`, which avoids dependency issues like `Can't resolve 'zlib-sync'`. * fix: standardize import quotes in README.md * style: organise imports --------- Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com> --- packages/core/README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/core/README.md b/packages/core/README.md index 088a6e4b5..ed90d42c6 100644 --- a/packages/core/README.md +++ b/packages/core/README.md @@ -71,6 +71,9 @@ gateway.connect(); ## Independent REST API Usage ```ts +import { API } from '@discordjs/core/http-only'; +import { REST } from '@discordjs/rest'; + // Create REST instance const rest = new REST({ version: '10' }).setToken(token);