react-hooks-snippets
react-hooks-snippets copied to clipboard
Custom settings for snippets
Hi,
I want to use the snippets with my custom settings.
For example, if I type ueh, it will automatically create return cleanUp = () => {} although I don't want it.
You know, we hardly have a cleanup callback except for some special cases such as setTimeout, setInterval, ....
Please tell me if you can somehow improve this situation.
I do appreciate this extension.
Thanks!
Hey @dan0705 thanks for the suggestion. In order to add extension controls with json settings I'll have to rebuild the extension in Typescript to allow for json setting contributions.
I have been planning to do so but can't give you a definitive timeline since this'll be new territory for me. I'll keep this issue open so I can let you know when I get around to it!
Hey @dan0705 thanks for the suggestion. In order to add extension controls with json settings I'll have to rebuild the extension in Typescript to allow for json setting contributions.
I have been planning to do so but can't give you a definitive timeline since this'll be new territory for me. I'll keep this issue open so I can let you know when I get around to it!
I'm looking forward to using it. Thank you!
Maybe just a setting to disable the cleanUp = () syntax? I'm pretty sure that syntax will generate errors with most linters not just TypeScript.
Hey thanks for the reminder @rsxdalv , I still plan on tackling this.
The project got away from me for a little while but I don't see why re-writing it in Typescript would be an issue. Once that's done, we'll have the ability to add options for different variations of hooks, semi/no-semi, etc 👍🏻
Thank you for the snippets. Thank to your extension source, I can know the syntax and write my own snippet file for VSCode.
I no longer have the time to add new features to this extension, feel free to open a pr if you have the time!
I understand and I'm in the same boat. I think if someone really needs this, they could make another "ueh2" snippet without the cleanup. Personally I think with AI code completion I barely need snippets anymore.
On Sat, Sep 16, 2023, 1:16 AM Al Duncanson @.***> wrote:
Closed #15 https://github.com/alDuncanson/react-hooks-snippets/issues/15 as completed.
— Reply to this email directly, view it on GitHub https://github.com/alDuncanson/react-hooks-snippets/issues/15#event-10387879011, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTRXIYPI7SSH5XMXOVRMSLX2THVBANCNFSM4TBZN5NQ . You are receiving this because you were mentioned.Message ID: @.*** com>