hookstate icon indicating copy to clipboard operation
hookstate copied to clipboard

Feature: give `none` an explicit type

Open parisholley opened this issue 2 years ago • 1 comments

Because none has an any type, using eslint with the rule @typescript-eslint/no-unsafe-argument will complain everywhere it is used. perhaps we update api with a state.clear() or just use a dummy global class instance

parisholley avatar Aug 22 '22 19:08 parisholley

yes, makes sense

On Tue, Aug 23, 2022 at 7:18 AM Paris Holley @.***> wrote:

Because none has an any type, using eslint with the rule @typescript-eslint/no-unsafe-argument will complain everywhere it is used. perhaps we update api with a state.clear() or just use a dummy global class instance

— Reply to this email directly, view it on GitHub https://github.com/avkonst/hookstate/issues/326, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA6JSVOOXK3KXXGZTROC4XLV2PHAHANCNFSM57IZUGFQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

avkonst avatar Aug 28 '22 10:08 avkonst

You can add an extension method clear() to a state, if you would like to hide the usage of none.

avkonst avatar Dec 19 '22 02:12 avkonst