Back to Content

Ink

files/en-us/web/api/ink/index.md

latest740 B
Original Source

{{APIRef("Ink API")}}{{SeeCompatTable}}

The Ink interface of the Ink API provides access to {{domxref("DelegatedInkTrailPresenter")}} objects for the application to use to render ink strokes.

{{InheritanceDiagram}}

Instance methods

  • {{domxref("Ink.requestPresenter", "requestPresenter()")}} {{Experimental_Inline}}
    • : Returns a {{jsxref("Promise")}} that fulfills with a {{domxref("DelegatedInkTrailPresenter")}} object to handle rendering strokes.

Example

js
async function inkInit() {
  const ink = navigator.ink;
  let presenter = await ink.requestPresenter({ presentationArea: canvas });

  // …
}

Specifications

{{Specifications}}

Browser compatibility

{{Compat}}