Answer the question
In order to leave comments, you need to log in
How to properly format imports?
How to properly (and why) format imports like
1) "table"
import ComponentOne from '@/components';
import ComponentTwo from '@/components/Two';
import ComponentThree from '@/components/Three';
import ComponentOne from '@/components';
import ComponentTwo from '@/components/Two';
import ComponentThree from '@/components/Three';
Answer the question
In order to leave comments, you need to log in
It's not organization, it's formatting. I agree with Anton, if you use VS Code, there are already extensions there, they do everything themselves. Although it can be configured.
I personally prefer the first option for both imports and assignments and arrays etc.
I think there is no “how to” answer, unless you are writing code for a common project where there is an explicit code formatting guide.
Clearly spelled out in the autoformatter settings, such as eslint or prettier.
They customize their own style.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question