Skip to content
This repository was archived by the owner on Oct 18, 2024. It is now read-only.

Commit def6df8

Browse files
committed
add livewire 3 compatibility
1 parent 920c6a6 commit def6df8

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/preload/index.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@ ipcRenderer.on('log', (event, {level, message, context}) => {
1616

1717
// Add Livewire event listeners
1818
ipcRenderer.on('native-event', (event, data) => {
19+
20+
// add support for livewire 3
21+
// @ts-ignore
22+
if (window.Livewire) {
23+
// @ts-ignore
24+
window.Livewire.dispatch('nativephp:' + data.event, data.payload);
25+
}
26+
1927
// @ts-ignore
2028
if (!window.livewire) {
2129
return;

0 commit comments

Comments
 (0)