poblish / bannedList-Plugin

#BannedList Plugin
3 stars 1 forks source link

Chrome prefs need to be persisted #16

Closed poblish closed 12 years ago

poblish commented 12 years ago

... not lost each time the page reloads. Proposal is:

"Basically, CS asks (new) Background HTML's JS snippet to send it the options. Once received, call the update method. As for the Back JS, return the default options if none are set. Need to test this somehow... there's no way to clear an extension's LS (you could do a null/blank check, I guess))."

http://stackoverflow.com/questions/3937000/chrome-extension-accessing-localstorage-in-content-script

poblish commented 12 years ago

PS. Is there anything else we can cache on the back-end? Need the DOM and the regexes in the same place, so prob, doesn't make sense to have to pass them around. Besides, the regex compile time appears to be miniscule. Don't worry about it for now.

poblish commented 12 years ago

Fixed as above.