elderfo / react-native-storybook-loader

An automatic story loader for react-native-storybooks
https://github.com/elderfo/react-native-storybook-loader
MIT License
299 stars 27 forks source link

Typescript support? #84

Closed jdoroy closed 5 years ago

jdoroy commented 5 years ago

First of all, thank you for this awesome project. I just want to know if I can use this with typescript? I've tried doing so but I haven't yet succeeded.

I've followed the instructions here: https://storybook.js.org/docs/configurations/typescript-config/. Tried using both babel-loader and awesome-typescript-loader but no luck.

Here's the screenshot of what I'm experiencing:

Screen Shot 2019-09-25 at 4 27 50 PM
odjhey commented 5 years ago

do you mean 'detect stories written in typescript?' If so, yes, it works fine, im using it with typescript. I just changed the pattern to "pattern": "**/*.story.tsx" in my package.json

I suggest to try and make your Storybook (in typescript) work first before installing RNSTL.

jdoroy commented 5 years ago

@odjhey Yup, I've already resolve the issue by doing so. Thank you, anyway 🙏

Turned out that the error is caused by react-native caching issue.