pub struct NargoFormatter { /* private fields */ }Expand description
格式化 Nargo 相关文件的工具
支持格式化 Nargo、TS、TSX、JS、JSX 文件,能够处理 Nargo 单文件组件的不同区块。
Implementations§
Source§impl NargoFormatter
impl NargoFormatter
Sourcepub fn with_config(config: FormatterConfig) -> Self
pub fn with_config(config: FormatterConfig) -> Self
Sourcepub fn load_config_from_file(file_path: &str) -> Result<FormatterConfig>
pub fn load_config_from_file(file_path: &str) -> Result<FormatterConfig>
Sourcepub fn save_config_to_file(
config: &FormatterConfig,
file_path: &str,
) -> Result<()>
pub fn save_config_to_file( config: &FormatterConfig, file_path: &str, ) -> Result<()>
Auto Trait Implementations§
impl Freeze for NargoFormatter
impl !RefUnwindSafe for NargoFormatter
impl Send for NargoFormatter
impl Sync for NargoFormatter
impl Unpin for NargoFormatter
impl UnsafeUnpin for NargoFormatter
impl !UnwindSafe for NargoFormatter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more