Skip to content
This repository has been archived by the owner on Sep 8, 2021. It is now read-only.

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
swyxio authored Nov 12, 2018
1 parent df120f4 commit 48f7e95
Showing 1 changed file with 24 additions and 1 deletion.
25 changes: 24 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,15 @@
# netlify-chrome-extension
# netlify-browser-extension

Get it:

- [for Chrome](https://chrome.google.com/webstore/detail/netlify-chrome-extension/dkhfpnphbcckigklfkaemnjdmghhcaoh)
- for Firefox (not available yet)
- for Edge (not available yet)

---


## Explanation

This is a tiny little browser extension that does a couple things:

Expand All @@ -15,3 +26,15 @@ This is a tiny little browser extension that does a couple things:
- not active

PRs/feature suggestions welcome

---

## How it works

Honestly its probably more complicated than needs to be but i based it off of other extensions that do the same thing.

- inject `content-script` into every page
- script pings `background.js` that there is a new page
- `background.js` activates the "browser action" (the little logo on the browser bar) if its a Netlify site by sniffing the `Server` field in the response header.
- if it is a Netlify site and you click the "browser action":
- if it is on `.netlify.com` host, `popup.js` checks if it is open source and manipulates `popup.html` accordingly.

0 comments on commit 48f7e95

Please sign in to comment.