Typescript Errors
Closed this issue · 1 comments
dzlandis commented
When building my application with tsc, I get the following errors from this package:
9 export default async function whisper(filePath: string, whisperOptions?: object): Promise<TranscriptType[]> {
~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/whisper-node/whisper.ts:4:46 - error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ en_base: string; en_medium: string; large: string; }'.
No index signature with a parameter of type 'string' was found on type '{ en_base: string; en_medium: string; large: string; }'.
4 `./main ${getFlags(options)} -m ./models/${models[model]} -f ${filePath} `;
~~~~~~~~~~~~~
Found 2 errors in 2 files.
Errors Files
1 node_modules/whisper-node/index.ts:9
1 node_modules/whisper-node/whisper.ts:4```
Additionally, the usage example in the README is inaccurate as the whisper function does not take in an object and instead takes in a string, meaning it doesn't work as intended.
ariym commented
It's now Promise