You can read about Speech Synthesis Web-API [1], [2], is supported to some extent by several browsers [3]
Here is a basic example
let utterance = new SpeechSynthesisUtterance(
"I want to get this text uttered (on a specific device)"
);
utterance.lang = 'en';
speechSynthesis.speak(utterance);
Is it possible to specify the audio output where it will play?
(it could use a chromium extension if necessary)