Skip to content

Commit

Permalink
fix:windows voices is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
tk103331 committed Mar 6, 2023
1 parent 488e249 commit fa96092
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/view/settings/General.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ export default function General() {

useInit(async () => {
setPlatform(await platform());
speechSynthesis.addEventListener('voiceschanged', () => {
const voices = speechSynthesis.getVoices();
console.log(voices);
setVoices(voices);
});
setVoices(speechSynthesis.getVoices());
});

Expand Down

0 comments on commit fa96092

Please sign in to comment.