All notable changes to the "sortjsobject*keys" extension will be documented in this file.
- Use natural sort order for the key/value with or without quotes
- Support nested object sorting
e.g:Will be formatted to:{ user: 'user', aaa: { index: '321', id: '123' }, bbb: 'bbb', password: 'password' }
{ aaa: { id: '123', index: '321' }, bbb: 'bbb', password: 'password', user: 'user' }
-
Update parser to use @babel/parser to parse the code
-
Support Typescript
as
expression: e.g:{ user: { name: 'Xingxin', age: 26 } as IPerson, date: '02/03/2018' as any, message: 'this is message', password: '****' as IPassword }
Will be formated to:
{ date: ('02/03/2018' as any), message: 'this is message', password: ('****' as IPassword), user: ({ name: 'Xingxin', age: 26 } as IPerson) }
-
Use babylon + babel/generator to parse and genertate the code
-
Support all the existing feature except:
- Auto add tailing comma (Too much bugs for this feature)
- End line comments (Babel can't parse it correctly)
-
Initial release of a testing version
-
Add
Sort JS object keys
command -
Add
Sort JS object keys (Reverse)
command -
Lots of feature in test version...