YouTube Distraction Blocker v4.1
Each page has a different local storage
Understand Background action vs Browser action
Background Script has the context of the extension while
Content Script has the context of the web page. It has restrictions on CORS so only the Background Script can run the CORS API requests.
Content Script sends a Chrome message to the Background Script on whether to block the YouTube video or not
Logo was made in Adobe Photoshop
Resources needed are:
Youtube Data API