Skip to main content

Native Invokes JS Function (NativeCallJS)

AndroidiOSWindows
If you are using the Unity engine, see Unity SDK's NativeCallJS.

Interface for Interaction between Native and Webpage JS.

Function Definition

UFUNCTION(BlueprintCallable, Category = "INTLSDKAPI")
static bool CallJS(const FString JsonJsParam);

Parameter Instructions

ParametersTypeExplanation
JsonJsParamFStringJavaScript to be Executed

Code Sample

UINTLSDKAPI::CallJS("alert(navigator.userAgent);");