shoonyatech / frontend.social

Frontend Social website
https://www.frontend.social
MIT License
11 stars 19 forks source link

styles(CourseDetails): re-arrange import orders #511

Closed kalpeshsingh closed 3 years ago

kalpeshsingh commented 3 years ago

Fixes https://github.com/shoonyatech/frontend.social/issues/510

souvikbasu commented 3 years ago

is there a way to automate this for every file. I guess there are some VS code extensions or npm package that can format code to rearrange the import statements. If not, we will do it manually, but better if there is a tool for it.

kalpeshsingh commented 3 years ago

is there a way to automate this for every file. I guess there are some VS code extensions or npm package that can format code to rearrange the import statements. If not, we will do it manually, but better if there is a tool for it.

A quick Google search showed that there are couple of import re-order npm packages and VS Code extensions. They usually do sorting of modules, arrange them in alphabetical order etc.

Our purpose to re-order imports based on categories which is yet to be in mainstream. Also, we want to keep comment on each import category for quick search.

We should always go for automation whenever possible but seems like we don't have much here. I have posted on Twitter and see if we can helpful response.

souvikbasu commented 3 years ago

Ok thanks Kalpesh. In that case, let me merge this PR. Will wait for if we can find any solution to automate this. If not we will manually fix all files as per sample here.