YouTube Blocker blocks YouTube videos not in the Education, Science & Technology, or Howto & Style categories so you can focus on educational videos.
- fork repo if desired
- clone repo locally
- go to chrome://extensions
- Press
Load unpacked
in top left corner - Select your cloned youtube-blocker folder
- Enable the extension and develop in your IDE.
- Changes should reflect automatically after you save
- If not, then press the refresh button on the extension card in the chrome://extensions page
- DF tube chrome extension
- Unhook chrome extension
- 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
- Background page replaced with Service Worker
- background pages provide an environment that lives independent of any other window or tab. This allows extensions to observe and act in response to events.
- Resources Used:
- Chrome Extension API
- Youtube Data API