sindresorhus / emoj

Find relevant emoji from text on the command-line :open_mouth: :sparkles: :raised_hands: :horse: :boom: :see_no_evil:
MIT License
2.36k stars 57 forks source link

Upgrade to Ink 3 #46

Closed vadimdemedes closed 4 years ago

vadimdemedes commented 4 years ago

CleanShot 2020-06-23 at 21 16 53

Also rewritten the whole thing using hooks.

sindresorhus commented 4 years ago

After searching, if I press Escape to leave, I get this:

❯ node cli.js

› horse

Warning: Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
    in Emoj (created by Context.Consumer)
    in Unknown
    in App
sindresorhus commented 4 years ago

Thanks for upgrading this. The changes look great and much more readable now with hooks.

vadimdemedes commented 4 years ago

Fixed everything, including that warning on exit:

Warning: Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
    in Emoj (created by Context.Consumer)
    in Unknown
    in App