Webview:onReady() event


This event is fired when the Webview have been initialized and is ready to load a web page.
This event allows in particular to make adjustments before the first web page is displayed (for example, deactivating the status bar, deactivating developer tools, adding JavaScript scripts, etc.)

Example

local ui = require "ui" require "webview" -- create a fixed Window local win = ui.Window("Webview:align() sample", "fixed", 320, 200) -- create a Webview without an URL local wv = ui.Webview(win, "", 25, 25) -- align the Webview in all of its parent area wv.align = "all" -- Once the webview widget is ready, navigate to the specified URL function wv:onReady() wv.url = "https://wwww.luart.org" end -- shows the Window win:show() while win.visible do ui.update() end

Return value

The event returns no value.