@untemps/vocal 2.0.0-beta.25 → 2.0.0-beta.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/README.md +13 -1
  3. package/package.json +14 -6
package/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ # [2.0.0-beta.27](https://github.com/untemps/vocal/compare/v2.0.0-beta.26...v2.0.0-beta.27) (2026-05-22)
2
+
3
+ # [2.0.0-beta.26](https://github.com/untemps/vocal/compare/v2.0.0-beta.25...v2.0.0-beta.26) (2026-05-22)
4
+
1
5
  # [2.0.0-beta.25](https://github.com/untemps/vocal/compare/v2.0.0-beta.24...v2.0.0-beta.25) (2026-05-22)
2
6
 
3
7
  # [2.0.0-beta.24](https://github.com/untemps/vocal/compare/v2.0.0-beta.23...v2.0.0-beta.24) (2026-05-22)
package/README.md CHANGED
@@ -6,10 +6,22 @@ Functional wrapper around the SpeechRecognition Web API
6
6
  ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/untemps/vocal/publish.yml?style=for-the-badge)
7
7
  ![Codecov](https://img.shields.io/codecov/c/github/untemps/vocal?style=for-the-badge)
8
8
 
9
+ ## Requirements
10
+
11
+ - A modern browser exposing the `SpeechRecognition` Web API (Chrome, Edge, Safari ≥ 14.1). The library is browser-only — it cannot run on the server.
12
+ - **TypeScript ≥ 6.0** for full type resolution. The published declarations rely on `SpeechRecognitionEvent` and `SpeechRecognitionErrorEvent` shipped by `lib.dom` starting with TypeScript 6.0. If you target an older TypeScript release, install [`@types/dom-speech-recognition`](https://www.npmjs.com/package/@types/dom-speech-recognition) to provide the missing ambient declarations.
13
+
9
14
  ## Installation
10
15
 
11
16
  ```bash
17
+ # yarn
12
18
  yarn add @untemps/vocal
19
+
20
+ # npm
21
+ npm install @untemps/vocal
22
+
23
+ # pnpm
24
+ pnpm add @untemps/vocal
13
25
  ```
14
26
 
15
27
  ## Basic Usage
@@ -85,7 +97,7 @@ Please refer to [this section](https://developer.mozilla.org/en-US/docs/Web/API/
85
97
  | end | Fired when the recognition service has disconnected |
86
98
  | error | Fired when a recognition error occurs |
87
99
  | nomatch | Fired when the recognition service returns a final result with no significant recognition |
88
- | result | Fired when the recognition service returns a result — callback receives `(event, bestAlternative: string, alternatives: string[])` where `bestAlternative` is the alternative with the highest confidence |
100
+ | result | Fired when the recognition service returns a result — callback receives `(event, bestAlternative: string, alternatives: string[])` where `bestAlternative` is the alternative with the highest confidence. **In `continuous: true` mode, intermediate final results are deferred until explicit `stop()` (see [Aggregated result on stop](#aggregated-result-on-stop)).** |
89
101
  | soundend | Fired when any sound — recognisable or not — has stopped being detected |
90
102
  | soundstart | Fired when any sound — recognisable or not — has been detected |
91
103
  | speechend | Fired when speech recognized by the recognition service has stopped being detected |
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@untemps/vocal",
3
- "version": "2.0.0-beta.25",
4
- "description": "Class wrapped around the SpeechRecognition Web API",
3
+ "version": "2.0.0-beta.27",
4
+ "description": "Functional wrapper around the SpeechRecognition Web API",
5
5
  "repository": "git@github.com:untemps/vocal.git",
6
6
  "keywords": [
7
7
  "Web Speech API",
@@ -21,15 +21,15 @@
21
21
  "node": ">=22"
22
22
  },
23
23
  "files": [
24
- "dist/index.cjs",
25
- "dist/index.es.js",
26
- "dist/index.d.ts",
27
- "dist/Vocal.d.ts",
24
+ "dist/*.cjs",
25
+ "dist/*.es.js",
26
+ "dist/*.d.ts",
28
27
  "CHANGELOG.md"
29
28
  ],
30
29
  "main": "dist/index.cjs",
31
30
  "module": "dist/index.es.js",
32
31
  "types": "dist/index.d.ts",
32
+ "sideEffects": false,
33
33
  "exports": {
34
34
  ".": {
35
35
  "types": "./dist/index.d.ts",
@@ -63,6 +63,14 @@
63
63
  "dependencies": {
64
64
  "@untemps/user-permissions-utils": "^1.3.3"
65
65
  },
66
+ "peerDependencies": {
67
+ "typescript": ">=6.0.0"
68
+ },
69
+ "peerDependenciesMeta": {
70
+ "typescript": {
71
+ "optional": true
72
+ }
73
+ },
66
74
  "release": {
67
75
  "branches": [
68
76
  "main",