File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 11.. _doc_web_javascript_bridge :
22
3- The JavaScriptBridge Singleton
3+ The JavaScriptBridge singleton
44==============================
55
66In web builds, the :ref: `JavaScriptBridge <class_JavaScriptBridge >` singleton
@@ -93,6 +93,12 @@ Arguments passed by JavaScript to the callback will be passed as a single Godot
9393 js_event.preventDefault()
9494 js_event.returnValue = ''
9595
96+ .. warning ::
97+
98+ The number of arguments accepted by the callback method (``_my_callback `` in the above example)
99+ **must ** match the number of arguments sent by JavaScript. Otherwise, the callback method will
100+ not be called.
101+
96102Here is another example that asks the user for the `Notification permission <https://developer.mozilla.org/en-US/docs/Web/API/Notifications_API >`__
97103and waits asynchronously to deliver a notification if the permission is
98104granted:
You can’t perform that action at this time.
0 commit comments