r5n-labs/vscode-react-javascript-snippets

Option to disable default exports (use named exports)?

andrei-ce opened this issue · 1 comments

Hi all,

as a suggestion I would like to either have a snippet or have a configuration setting for exporting react components as named imports only, without the default keyword. I know this is a personal preference but not having to delete the default keyword all the time would same some time.

As an example, adding the config below to VS Code's settings.json saved me a lot of time and I wish there was something to turn off default exports:
"reactSnippets.settings.importReactOnTop": false,

Either way, thanks this is already a great extension!

Thank you, Your description with the example helped me understand how to properly modify existing parameters. The read.me didn't mention anything about this, and as a newbie in such matters, I didn't immediately catch on to which keys to refer to.

I've created a PR #308 to add this explanation for others, but I'm not sure about the likelihood of it being accepted.