olefirenko / vue-barcode-reader

A Vue.js set of components to scan barcodes and QR codes.
214 stars 77 forks source link

Deprecate decode event #56

Open SassNinja opened 1 year ago

SassNinja commented 1 year ago

@olefirenko as I can see you've introduced the result event in https://github.com/olefirenko/vue-barcode-reader/pull/43 and kept the decode event to avoid a breaking change

However the README only shows usage of @decode which encourages people to still use it. I'd recommend to remove it entirely and only show the usage of @result. Going one step further could be an actual deprecation warning when using decode so that you might delete it in future.

Another thing I've noticed is you started describing the shape of the result

The result is the object with the following properties:

However this isn't finished since nothing follows the colon. I think it would be helpful to finish this 😉