Skip to content

Commit ff2a793

Browse files
committed
chore: Bump version of dprint-core to 0.35.0
1 parent 9cc87cf commit ff2a793

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "dprint-plugin-typescript"
33
description = "TypeScript and JavaScript code formatter."
44
keywords = ["formatting", "formatter", "typescript", "javascript"]
5-
version = "0.38.1"
5+
version = "0.38.2"
66
authors = ["David Sherret <[email protected]>"]
77
edition = "2018"
88
license = "MIT"
@@ -24,12 +24,12 @@ panic = "abort"
2424
wasm = ["serde_json", "dprint-core/wasm"]
2525

2626
[dependencies]
27-
dprint-core = { version = "0.34.0", features = ["formatting"] }
27+
dprint-core = { version = "0.35.0", features = ["formatting"] }
2828
fnv = "1.0.3"
2929
swc_common = "0.10.8"
3030
swc_ecmascript = { version = "0.17.0", features = ["parser"] }
3131
swc_ast_view = { version = "0.3.2", package = "dprint-swc-ecma-ast-view" }
32-
serde = { version = "1.0.118", features = ["derive"] }
32+
serde = { version = "1.0.119", features = ["derive"] }
3333
serde_json = { version = "1.0", optional = true }
3434

3535
[dev-dependencies]

src/format_text.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ pub fn format_text(file_path: &Path, file_text: &str, config: &Configuration) ->
4040
}
4141

4242
let parsed_source_file = parse_swc_ast(file_path, file_text)?;
43-
let print_items = parse(&parsed_source_file, config);
44-
45-
// println!("{}", print_items.get_as_text());
46-
47-
return Ok(print(print_items, PrintOptions {
43+
return Ok(dprint_core::formatting::format(|| {
44+
let print_items = parse(&parsed_source_file, config);
45+
// println!("{}", print_items.get_as_text());
46+
print_items
47+
}, PrintOptions {
4848
indent_width: config.indent_width,
4949
max_width: config.line_width,
5050
use_tabs: config.use_tabs,

0 commit comments

Comments
 (0)