fix(example/state): correct invoke method path to __TAURI__.core.invoke() (#9817)

This commit is contained in:
ryoichi 2024-05-19 18:16:23 +09:00 committed by GitHub
parent fe90a2925e
commit 0c61784efb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -35,14 +35,14 @@
}
incrementBtn.addEventListener('click', () => {
window.__TAURI__
window.__TAURI__.core
.invoke('increment_counter')
.then(updateResponse)
.catch(updateResponse)
})
storeBtn.addEventListener('click', () => {
window.__TAURI__
window.__TAURI__.core
.invoke('db_insert', {
key: KEY,
value: storeInput.value
@ -52,7 +52,7 @@
})
readBtn.addEventListener('click', () => {
window.__TAURI__
window.__TAURI__.core
.invoke('db_read', {
key: KEY
})