Skip to main content

move_node_in_source

Function move_node_in_source 

Source
pub fn move_node_in_source(
    source: &str,
    file: &RelativePath,
    node: &NodeRef,
    target: &NodeRef,
    position: InsertPosition,
) -> Result<MutationResult, String>
Expand description

Move a node to a new position relative to a target. Both nodes must be in the same file (same source text).