How to use typescript package (@portabletext/react) with Preact? #1696
Replies: 2 comments
-
Just thought I'd add that this happens on a fresh |
Beta Was this translation helpful? Give feedback.
-
Hm, that doesn't seem to be the case. The package certainly does distribute built files. Double check your imports, you shouldn't be importing from
|
Beta Was this translation helpful? Give feedback.
-
Hello,
I am trying to use @portabletext/react however whenever I build I get the following error: (Note: I was confused why this was in
node_modules
then realised the package isn't compiled (shipped as tsx)After doing some searching on the issues, I found preactjs/preact#3180 and updated my
tsconfig.json
Now when I run
preact watch
I get the following errors.I've tried to ignore these errors using
exclude
but wondering if there's a simple way to ignore typescript issues from a typescript package that's not shipped as compiled code?Beta Was this translation helpful? Give feedback.
All reactions