Open muke5hy opened 1 week ago
PLease provide more information including reproduction steps, package versions, etc.
You likely have incompatible versions of uploadthing
and @uploadthing/react
.
Make sure that you're within the accepted peer dependency ranges
You likely have incompatible versions of
uploadthing
and@uploadthing/react
.Make sure that you're within the accepted peer dependency ranges
I have updated with few more details. Which version should I use?
PLease provide more information including reproduction steps, package versions, etc.
I have updated the question with more details.
Oh, I see. That type doesn't really exist. We use it in the documentation to explain the shape of the data provided to the onUploadComplete
function. Docs might be a bit unclear on that. cc @juliusmarminge
(I think) that exists but it might have been renamed since it existed both on the server and client before
(I think) that exists but it might have been renamed since it existed both on the server and client before
Great, thanks for reply. But how do I use it. I tried following.
import type { ClientUploadedFileData } from 'uploadthing/client';
But still getting following error while building.
./src/components/file-upload.tsx:6:15
Type error: Module '"uploadthing/client"' declares 'ClientUploadedFileData' locally, but it is not exported.
4 | import { Trash } from 'lucide-react';
5 | import Image from 'next/image';
> 6 | import type { ClientUploadedFileData } from 'uploadthing/client';
| ^
7 | import { IMG_MAX_LIMIT } from './forms/product-form';
8 | import { Button } from './ui/button';
9 | import { useToast } from './ui/use-toast';
ELIFECYCLE Command failed with exit code 1.
```
import it from uploadthing/types
I understand that this issue may be closed if it should be filed in another category
My issue
Getting error
Module '"uploadthing/client"' has no exported member 'UploadFileResponse'.ts(2305)
Uploadthings versionThis is how I am importing the
UploadFileResponse
When I build the project I get following error