Replies: 1 comment
-
Assuming you don't do a lot of cookies and cookie removal I'd think localstorage would be a good option. Save the camera id that you pass on scan.
you'd want to wrap your current camera selection in an if block And if you want to remove the default at any point you have two choices standard practice with local storage is to use .remove('item'); so as to play nice with any other subdomains that also use localStorage, but if you need to clear it completely then .clear(); is your best bet, just be aware that if another developer on yoursite.com/section1 is using local storage and you clear it in yoursite.com/section2 then its going to clear all of their data as well. |
Beta Was this translation helpful? Give feedback.
-
I'm setting this up to use in a web page that will refresh with every valid scan so that the information scanned can be validated. Right now, the user has to reselect the camera and hit start scanning. Any ideas how to capture the camera preferences to store in a form for retrieval after the refresh?
Beta Was this translation helpful? Give feedback.
All reactions