You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm becoming quite fond of micro-observables and I'd like to use it in a library I'm writing that is not React based. I see 'react' is a peerDependency which will work fine but of course npm/yarn will complain of an unmet peerDependency.
Thanks for your feedback. You're right, micro-observables is not tightly coupled to React and it is probably a good idea to split it into two packages. The optionalDependency option is unfortunately not a good solution for this, as it only specifies that if the dependency fails to install, npm install will still succeed. It means that running npm install micro-observables will actually install react in your project.
I'll probably split the library into two packages in the near future, I'll update this issue when this is done.
I'm becoming quite fond of micro-observables and I'd like to use it in a library I'm writing that is not React based. I see 'react' is a peerDependency which will work fine but of course npm/yarn will complain of an unmet peerDependency.
The only react requirement if the hooks within https://github.com/BeTomorrow/micro-observables/blob/master/src/hooks.ts#L1, a thought would be to package this as a separate library just for the hook? or I believe making 'react' an optionalDependency might work as well.
The text was updated successfully, but these errors were encountered: