SDK JS
    Preparing search index...

    Interface ProfileController

    The headless profile API returned by createProfileController.

    const profile = createProfileController({ map });
    profile.start(); // click along the ground; dblclick or Enter finishes the line
    profile.draw.cancel(); // abandon an in-progress line (Escape does the same)
    console.log(profile.run?.stats.lengthM);
    interface ProfileController {
        draw: DrawController;
        run: ProfileRun | null;
        clear(): void;
        dispose(): void;
        start(): void;
    }
    Index

    Properties

    Methods

    Properties

    The shared draw controller (start/cancel/clear the line).

    run: ProfileRun | null

    The latest ProfileRun, or null before a line is finished.

    Methods

    • Clear the line + run.

      Returns void

    • Unbind everything (widget teardown).

      Returns void

    • Begin drawing a new profile line.

      Returns void