You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to use Via.js inside a Vue app. I am finding it difficult to import the receiver. I keep getting a typescript error of 'cannot find this module'. Can you correct my work. Here is what I have so far:
Hello World
Click
<script setup lang="ts">
import ViaReceiver from 'via.js/receiver';
onMounted(() => {
let worker = new Worker("worker.js");
// Hook up Via's messages with the worker's postMessage bridge
worker.onmessage = (e => ViaReceiver.OnMessage(e.data));
ViaReceiver.postMessage = (data => worker.postMessage(data));
// Start the worker
worker.postMessage("start");
})
</script>
Yours Sincerely
Anthony Jekanyika
The text was updated successfully, but these errors were encountered:
I am trying to use Via.js inside a Vue app. I am finding it difficult to import the receiver. I keep getting a typescript error of 'cannot find this module'. Can you correct my work. Here is what I have so far:
Hello World
ClickYours Sincerely
Anthony Jekanyika
The text was updated successfully, but these errors were encountered: