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

revolt-api not found #11

Open
LouisMarotta opened this issue Apr 11, 2022 · 1 comment
Open

revolt-api not found #11

LouisMarotta opened this issue Apr 11, 2022 · 1 comment

Comments

@LouisMarotta
Copy link

I've tried building the base template from master, but i keep getting this error in /src/events/ready.ts even though all the dependencies are installed

src/events/ready.ts:1:26 - error TS2307: Cannot find module 'revolt-api/types/Users' or its corresponding type declarations.
import { Presence } from "revolt-api/types/Users";
@ghost
Copy link

ghost commented Mar 18, 2023

Apparently this is an issue with current versions of revolt.js

you need to add an enum before the ready event function:

enum Presence {
    Online = "Online",
    Idle = "Idle",
    Busy = "Busy",
    Invisible = "Invisible"
}

and remove the import at the top of the file

It should look something like this:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant