Plugin API - liri-project/liri-browser GitHub Wiki
Liri Plugin API
Features and Permissions
commonnetworkomnipletbookmarkshistory
Actions
bool liri.fetchURL(string url, function callback(content))
Fetches web content. The text is returned as first argument of callback. Returns false if the access was blocked because of insufficient permissions else true. Requires feature network.
bool liri.appendSearchSuggestion(string text, string icon, string insertMode="end")
Appends a search suggestion. Requires feature omniplet.
array liri.getHistory()
Returns the browser history as array. Requires feature history.
array liri.getBookmarks()
Returns the browser bookmarks as array. Requires feature bookmarks.
Register events
bool liri.on(string event, function callback)
Registers callback for event event. Returns true if the operation was successful or false if it failed. It will fail if event is unknown or the plugin has insufficient permissions.
Events
loadCalled on plugin load.omnibox.searchTriggered when text of the omnibox has changed. Requires featureomniplet