blockly > utils > svgPaths > lineOnAxis

utils.svgPaths.lineOnAxis() function

Draw a horizontal or vertical line. The first argument specifies the direction and whether the given position is relative or absolute. These coordinates are unitless and hence in the user coordinate system. See


export declare function lineOnAxis(command: string, val: number): string;


Parameter Type Description
command string The command to prepend to the coordinate. This should be one of: V, v, H, h.
val number The coordinate to pass to the command. It may be absolute or relative.



A string of the format ' command val '