tr3v3r / react-native-esc-pos-printer

An unofficial React Native library for printing on an EPSON TM printer with the Epson ePOS SDK for iOS and Epson ePOS SDK for Android
MIT License
137 stars 64 forks source link

Permissions printing if you have never discovered #131

Open Sheaffy opened 5 months ago

Sheaffy commented 5 months ago

I stumbled across this when implementing this lib. (Nice work so far btw!)

I noticed that if you happen to already know the bluetooth address and attempt to connect to it without ever using discovery, it does not prompt for permissions through the lib.

Correct me if I'm wrong, but I'm thinking it may be beneficial to document that you could use the "requestAndroidPermissions" function in the permissions util in "react-native-esc-pos-printer/src/core/utils/permissions" to achieve this before you attempt to connect. (Should you not use discover)

Happy to make a PR containing documentation if you would like.