Closed unfernandito closed 2 years ago
That's strange because the latest version comes with pre built js and d.ts files in dist folder. Try deleting node_modules folder then run npm install again.
i'll try
After run a fresh install i got the same behavior, my tsc continue broken, looks like something related to my tsconfig, i'll try update typescript to 4.5 version
i've updated to typescript 4.5.5 and continue failing me, i'll try some other stuff and if i find something, i'll send you a PR
@ammarahm-ed i can't make a fork to try to fix it, but i think is broken the reference to the declaration files. I think this problem it's related to my config. but i can't figure out which could be the issue.
In other way, i think the dist folder should only exist while is running the publish action, right now your dist folder is outdated, if you run the npm run build
script, the files changed and maybe something is failing.
I think the type MMKVStorage.API does not exist in the latest typings which is why you are getting this error
https://github.com/ammarahm-ed/react-native-mmkv-storage/blob/master/dist/index.d.ts#L9
Seems exist in the declaration file, it's so weird.
@unfernandito Can you try the master branch? I have fixed this.
Use import {API} from "react-native-mmkv-storage"
instead for types
i'll try it
Ok, API namespace it's fixed, but all the others are no exported, how can i contribute you with this changes?
The repo seems to be reach the maximum forks allowed
@unfernandito You have already forked it I think. Check your repositories list. Which others are you using?
🕺 i'm so dumb, you are right, i've already forked this repo
Hey @unfernandito Can you try the master again and see if it resolves all errors? The PR you have sent is a breaking change and I am looking for a way to not break the API. You can now export MMKVStorageInterface
for any types you need.
I'll try, thanks you
El mar., 19 de abril de 2022 4:28 p. m., Ammar Ahmed < @.***> escribió:
Hey @unfernandito https://github.com/unfernandito Can you try the master again and see if it resolves all errors? The PR you have sent is a breaking change and I am looking for a way to not break the API. You can now export MMKVStorageInterface for any types you need.
— Reply to this email directly, view it on GitHub https://github.com/ammarahm-ed/react-native-mmkv-storage/issues/236#issuecomment-1103012695, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQIPKXXAIICXUAT2V3HFRDVF4CORANCNFSM5TVZI7UA . You are receiving this because you were mentioned.Message ID: @.***>
Same behavior :/
i've change the code to this and seems work again.
@ammarahm-ed could you publish this version in npm plz?
The latest commit can be applied as a fix to this issue 😄
Hi @ammarahm-ed how are you?
Could you publish the 0.7.3 version with the latests changes?
If you need some help, i'm available to contribute you in this repository.
@unfernandito I will merge the changes after undoing my last commits
Thanks you
El mié., 27 de abril de 2022 8:12 a. m., Ammar Ahmed < @.***> escribió:
@unfernandito https://github.com/unfernandito I will merge the changes after undoing my last commits
— Reply to this email directly, view it on GitHub https://github.com/ammarahm-ed/react-native-mmkv-storage/issues/236#issuecomment-1110875699, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQIPKRDLSXRSV4AG7VQFZ3VHEOLVANCNFSM5TVZI7UA . You are receiving this because you were mentioned.Message ID: @.***>
@unfernandito Check the latest master branch. Use import {MMKVLoader} from "react-native-mmkv-storage"
. I have renamed exports to more readable forms.
API is renamed to MMKVInstance Loader is renamed to MMKVLoader
Thanks friend. I'll try tomorrow and come back with the results.
All it's working well, this change will be breaking change?
My fault :(
@unfernandito No it won't be a breaking change. Only deprecating previous API but it still works the same way.
I will close this. Will ship it in 0.7.2
Thanks for all this work!
Describe the bug
Hello @ammarahm-ed how are you?
The latest version broke my typescript build, looks like cannot find the index.d.ts file in the package.
To Reproduce Steps to reproduce the behavior:
Expected behavior Build my typescript code.
Screenshots
Platform Information:
Additional context I tried with the 0.7.0 version and got the same error.