AhsanAyaz / AhsanAyaz/ngx-device-detector

Improve type for Browsers

Aperta
#283 0 commenti 1 reazione 0 assegnatari Vedi su GitHub
Lingua principale
TypeScript
Stelle
559
Fork
106
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

**Is your feature request related to a problem? Please describe.**
[Currently](https://github.com/AhsanAyaz/ngx-device-detector/blob/master/projects/ngx-device-detector/src/lib/device-detector.service.ts#L13) the type for `browser` in `DeviceInfo` is `string`.

**Describe the solution you'd like**
I'd like to narrow down the type to only the string values of reported browsers.

Please see the proof of concept of what I am looking for on the [TypeScript Playground here](https://www.typescriptlang.org/play?#code/KYDwDg9gTgLgBAYwgOwM7wOIFEByWBKAggDJwC8cA3gFBxwCqA0jgPIDqOAXHAOT3IBrZBADuyHgBpqAXzgBDVIhToA3NWqhIsJWngAhfOwDKBI+Sq04AYQAShgLJZuPKwAsoEALbBJlgGIAkvhYfiwAGs5+AJZQwABmECC+dEaEfoT4Ac5GcnFyUFHJcCwACgSEzixgwFByRQFOvA1F9kYA+lgAItjOrQC0WAAmAOY+UnStHd1YbbYOAfT2vUYDI8B9bh6eUQCunkV+em2ORqk42PiRen32wKiocsijUEWprfTn2XKeqDtPRfQrAZjARnIC+noPCJUDUAThmOwuHBsHgiMQAHRMVgcKSyBQ6VTqGAAT2qcEhIggMKgjGAxMUFAEdIgcTgJOqLPJhjYJnwRjU6k00Hg7OA5Kh1PMos5wJ5pgA2hSqTVafSALrqKLIGA1PIIMWdYAANyi+oCyASFjodAARhKatxIaJqWppEA).

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.