{"id":26643686,"url":"https://github.com/kosich/rxjs-tts","last_synced_at":"2025-04-10T23:51:18.599Z","repository":{"id":42768776,"uuid":"276691804","full_name":"kosich/rxjs-tts","owner":"kosich","description":"RxJS wrapper for Text-to-Speech Web API","archived":false,"fork":false,"pushed_at":"2023-01-07T19:43:56.000Z","size":576,"stargazers_count":8,"open_issues_count":10,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-24T20:38:43.108Z","etag":null,"topics":["javascript","rxjs","speech-synthesis","text-to-speech","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kosich.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-02T16:10:19.000Z","updated_at":"2023-12-07T13:39:17.000Z","dependencies_parsed_at":"2023-02-07T23:30:23.162Z","dependency_job_id":null,"html_url":"https://github.com/kosich/rxjs-tts","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kosich%2Frxjs-tts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kosich%2Frxjs-tts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kosich%2Frxjs-tts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kosich%2Frxjs-tts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kosich","download_url":"https://codeload.github.com/kosich/rxjs-tts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248317707,"owners_count":21083528,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["javascript","rxjs","speech-synthesis","text-to-speech","typescript"],"created_at":"2025-03-24T20:34:39.903Z","updated_at":"2025-04-10T23:51:18.580Z","avatar_url":"https://github.com/kosich.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003ch1\u003e\n    \u003cbr/\u003e\n    🗣\n    \u003cbr/\u003e\n    \u003csub\u003e\u003csub\u003eWeb API Text-to-Speech with RxJS\u003c/sub\u003e\u003c/sub\u003e\n    \u003cbr/\u003e\n    \u003cbr/\u003e\n    \u003ca href=\"https://www.npmjs.com/package/rxjs-tts\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/rxjs-tts\" alt=\"NPM\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://bundlephobia.com/result?p=rxjs-tts@latest\"\u003e\u003cimg src=\"https://img.shields.io/bundlephobia/minzip/rxjs-tts?label=gzipped\" alt=\"Bundlephobia\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://opensource.org/licenses/MIT\" rel=\"nofollow\"\u003e\u003cimg src=\"https://img.shields.io/npm/l/rxjs-tts\" alt=\"MIT license\"\u003e\u003c/a\u003e\n    \u003cbr/\u003e\n    \u003cbr/\u003e\n    \u003cbr/\u003e\n  \u003c/h1\u003e\n\u003c/div\u003e\n\nThis is a RxJS wrapper around browser native [SpeechSynthesis](https://developer.mozilla.org/en-US/docs/Web/API/SpeechSynthesis).\n\nIt provides handy interface for chaining and aborting TTS.\n\nTry it [**online**](https://stackblitz.com/edit/rxjs-tts?file=index.ts)\n\n## Install\n\n```\nnpm i rxjs-tts\n```\n\n## Usage\n\n```js\nimport { speak } from 'rxjs-tts';\n\nspeak('Hello!').subscribe();\n```\n\n## Chained\n\n```js\nimport { speak } from 'rxjs-tts';\n\nconcat(\n    speak('Hello, mom!'),\n    speak('How are you?'),\n    speak('I miss you.'),\n).subscribe();\n```\n\n## Advanced usage\n\n```js\nimport { of, merge, concat, timer } from 'rxjs';\nimport { map, takeUntil } from 'rxjs/operators';\nimport { speak, SpeechSynthesisUtteranceConfig } from 'rxjs-tts';\n\nconst a: string = 'Hello, mom!';\n\nconst b: SpeechSynthesisUtteranceConfig = {\n    text: 'How are you?',\n    lang: 'en-UK',\n    pitch: 1,\n    rate: 1,\n    volume: 1,\n};\n\nconst c = new SpeechSynthesisUtterance('I miss you');\nc.rate = 1;\nc.lang = 'en-US';\nc.pitch = 1;\nc.rate = 1;\nc.volume = 1;\n\nconcat(speak(a), speak(b), speak(c)).subscribe((e: SpeechSynthesisEvent) =\u003e {\n    console.log(e.name);\n    console.log(e.type);\n});\n```\n\n## Enjoy 🙂\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkosich%2Frxjs-tts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkosich%2Frxjs-tts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkosich%2Frxjs-tts/lists"}