-
Notifications
You must be signed in to change notification settings - Fork 216
Open
@tunniclm
Description
Version: rss-parser@3.13.0
The following code works as expected but fails to compile under Typescript:
import Parser from 'rss-parser'; const parser = new Parser({ customFields: { feed: [['dc:language', 'language']] } });
Typescript error: Type '[string, string]' is not assignable to type 'string | number'. ts(2322)
It feels like this should be allowed for a few reasons:
- The README reads like it should work (no special case to say
feedis more restricted thatitem) - The default fields defined in
lib/fields.jsuse these types of values (eg['dc:publisher', 'publisher']) - It does appear to work correctly when ignoring the Typescript error
Metadata
Metadata
Assignees
Labels
No labels