• Show Prompt dialog. Work without Jodit object

    Parameters

    • this: unknown
    • msg: string
    • title: undefined | string | (() => false | void)

      Title or callback

    • callback: ((value) => false | void)

      callback. The first argument is the value entered

        • (value): false | void
        • Parameters

          • value: string

          Returns false | void

    • Optional placeholder: string

      Placeholder for input

    • Optional defaultValue: string

    Returns IDialog

    Example

    Jodit.Prompt("Enter your name", "Prompt Dialog", function (name) {
    if (name.length < 3) {
    Jodit.Alert("The name must be at least 3 letters");
    return false;
    }
    // do something
    });

Jodit PRO

If you like Jodit - try Jodit PRO