Expand description
The functionality you need is in the sorter
module.
Call [sorter::sort_file_contents
] with the file contents and the sorter options.
The parser
module contains the functions to parse the classes from a file.
The [parser::parse_classes_from_file
] function will return a HashMap<String, usize>
with the classes and their order.
You can use this to create a custom sorter. Using this customer sorter you can call [sorter::sort_file_contents
].
Modules§
- class_
wrapping - consts
- Contains different constants used in the library.
- defaults
- Contains the default Sorter and default Regex
- parser
- Create a sorter from a CSS file to sort classes in the order that they appear in the file
- sorter
- The module that sorts the classes in the file contents.