Skip to content

Commit

Permalink
JSO: add API to send beacon (#956)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ihromant authored Oct 3, 2024
1 parent 68a1b2e commit 2414d74
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions jso/apis/src/main/java/org/teavm/jso/browser/Navigator.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,10 @@ private Navigator() {

@JSBody(script = "return navigator.hardwareConcurrency")
public static native int hardwareConcurrency();

public static native boolean sendBeacon(String url);

public static native boolean sendBeacon(String url, String data);

public static native boolean sendBeacon(String url, JSObject data);
}

0 comments on commit 2414d74

Please sign in to comment.