mirror of https://github.com/tauri-apps/tauri
feat(lib) event keyword => evt
Signed-off-by: Daniel Thompson-Yvetot <denjell@quasar.dev>
This commit is contained in:
parent
f0d95a4244
commit
90ade25b5b
16
lib/tauri.js
16
lib/tauri.js
|
@ -78,16 +78,16 @@ export default class Tauri {
|
|||
<% if (ctx.dev) { %>
|
||||
/**
|
||||
* @name addEventListener
|
||||
* @description Add an event listener to Tauri back end
|
||||
* @param {String} event
|
||||
* @description Add an evt listener to Tauri back end
|
||||
* @param {String} evt
|
||||
* @param {Function} handler
|
||||
* @param {Boolean} once
|
||||
*/
|
||||
<% } %>
|
||||
static addEventListener(event, handler, once = false) {
|
||||
static addEventListener(evt, handler, once = false) {
|
||||
this.invoke({
|
||||
cmd: 'addEventListener',
|
||||
event,
|
||||
evt,
|
||||
handler: this.transformCallback(handler, once),
|
||||
once
|
||||
})
|
||||
|
@ -96,15 +96,15 @@ export default class Tauri {
|
|||
<% if (ctx.dev) { %>
|
||||
/**
|
||||
* @name emit
|
||||
* @description Emits an event to the Tauri back end
|
||||
* @param {String} event
|
||||
* @description Emits an evt to the Tauri back end
|
||||
* @param {String} evt
|
||||
* @param {Object} payload
|
||||
*/
|
||||
<% } %>
|
||||
static emit(event, payload) {
|
||||
static emit(evt, payload) {
|
||||
this.invoke({
|
||||
cmd: 'emit',
|
||||
event,
|
||||
evt,
|
||||
payload
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue