Closes #2204

master
Simon Sassi 6 years ago
parent
commit
9dff311e81
  1. 20
      Inject-JavaScript-Code.md

20
Inject-JavaScript-Code.md

@ -4,4 +4,22 @@ For example, some users want to make an Auto Refresh every X time because the se
```javascript
setInterval(function(){location.reload();}, 600000);
```
```
An other example is injecting custom CSS (user styles).
This can be done with following snippet:
```javascript
(()=>{ let css=`
/* START OF STYLE */
* {
color: red;
}
/* END OF STYLE */
`;
var ss = document.createElement("style");
ss.type = "text/css"; ss.innerHTML = css;
document.getElementsByTagName("head")[0].appendChild(ss); })();```
Loading…
Cancel
Save