
App uses react +TS + vite

Can you share your code?


Change this
import { account } from "../../appwrite";
To this
import { account } from "appwrite";

You'll also need initialize a client Check this

I am exporting that from a file called appwrite.d.ts

from root folder

Yes

I see now, why you've added the d
in the .d.ts

if I use .ts

this happens

Probably because it can't be the same name
Change it to appwriteConfig.ts
and the import and re test

okay

Changed it but same as above

What error now?

Ohh Yes,

For <:vite:1007379819660595291> vite
any files most be inside the src foler
Move the appwriteConfig.ts
into the src
one
And change the login to
import { account } from "../appwriteConfig";

Thanks its working
Recommended threads
- Looking for Partner
I'm looking for a partner for long-term collaboration. Of course, you'll get paid for it. If you are interested, please send a DM to me
- Looking for Partner
I'm looking for partner for long-term collaborating. Of course, I'll pay for you. If you are interested, Please DM me.
- Hola equipo de soporte,
Hola equipo de soporte, Estoy desarrollando una Function en Appwrite Cloud con Node.js 22 y el siguiente package.json: { "name": "upload-whitelist", "type"...
