fix: some edge cases around autoformatting (#485)
* wip: remove comment support from autofmt * fix: some edge cases around autoformatting * fix: revert readme * fix: failing test
This commit is contained in:
1 parent
3a5d1a2ff8
commit
3a30b36f68
11 files changed
+536
-141
No files matched your search
@@ -0,0 +1,22 @@
|
||||
#[test]
|
||||
fn formats_file_properly() {
|
||||
let src = include_str!("./samples/thing.rsx");
|
||||
|
||||
let formatted = dioxus_autofmt::fmt_file(src);
|
||||
let out = dioxus_autofmt::apply_formats(src, formatted);
|
||||
|
||||
println!("{}", out);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn already_formatted_file_properly() {
|
||||
let src = include_str!("./samples/pre.rsx");
|
||||
|
||||
let formatted = dioxus_autofmt::fmt_file(src);
|
||||
|
||||
dbg!(&formatted);
|
||||
|
||||
let out = dioxus_autofmt::apply_formats(src, formatted);
|
||||
|
||||
println!("{}", out);
|
||||
}
|
||||
Reference in new issue
Block a user