A prettier plugin that sorts import statements by either their length in descending order.
npm install --save-dev prettier-plugin-descending-imports
The plugin will be loaded by Prettier automatically. No configuration needed. It will sort by import statement length by default.