vueuse / vueuse

Collection of essential Vue Composition Utilities for Vue 2 and 3

Home Page:https://vueuse.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Speech recognition concatenates multiple results and gives wrong output

noook opened this issue · comments

Describe the bug

When using useSpeechRecognition() with interimResults: true, the output is malformed and joins multiple times the same sentence.

The issue only happens on mobile, because the APIs don't seem to be the same. Open the link to reproduction on mobile.

More info here: https://stackoverflow.com/questions/50953900/speech-to-text-web-api-returns-different-result-on-desktop-vs-mobile

Reproduction

https://stackblitz.com/edit/vitejs-vite-ywbonf?file=src%2FApp.vue

System Info

System:
    OS: macOS 14.0
    CPU: (10) arm64 Apple M1 Pro
    Memory: 100.30 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.11.0 - ~/.nvm/versions/node/v20.11.0/bin/node
    npm: 10.2.4 - ~/.nvm/versions/node/v20.11.0/bin/npm
    pnpm: 8.15.3 - ~/work/vueuse/node_modules/.bin/pnpm
    bun: 1.0.6 - ~/.bun/bin/bun
  Browsers:
    Chrome: 123.0.6312.59
    Safari: 17.0
  npmPackages:
    @vueuse/core: file:../../packages/core/dist => 10.8.0 
    @vueuse/metadata: file:../../packages/metadata/dist => 10.8.0 
    @vueuse/shared: file:../../packages/shared/dist => 10.8.0 
    vue: ^3.4.19 => 3.4.20

Used Package Manager

npm

Validations