fede4ka1245 / ymap3-components

React wrapper around ymaps v3
30 stars 1 forks source link

Types do not work without `@yandex/ymaps3-types` #4

Closed antokhio closed 6 months ago

antokhio commented 7 months ago

All types are basically any unless the @yandex/ymaps3-types installed on hosting project...

I think "@yandex/ymaps3-types": "^0.0.20", should be moved from devDependencies to dependencies in package.json.

But this is a suggestion....

And if you install it the typescript isn't happy: image

fede4ka1245 commented 7 months ago

You can install ymaps types in dev dependencies on project where you install this lib. So, there is no need to add this to dependencies

antokhio commented 7 months ago

Yep, but then all nodes are red ;(

Didn't yet found why that happens...

fede4ka1245 commented 6 months ago

fix typescript: https://codesandbox.io/p/sandbox/elegant-burnell-wxn9cy Now types work correctly. You just need to install types as dev dependencies: npm i -D @yandex/ymaps3-types@latest

antokhio commented 6 months ago

Hey, nice update, i see you fix quite a lot of stuff, anyways was trying to fix types, end up firing package https://github.com/sbcrmweb/react-ymaps3

This rectified types are good but still had issues on them :(.

Currently trying to find time to move script loading under suspense, investigate type issues...