Skip to content

Instantly share code, notes, and snippets.

@andresh3
Last active November 3, 2023 02:43
Show Gist options
  • Save andresh3/63446c7ce7e65eed0f216888e66ce79f to your computer and use it in GitHub Desktop.
Save andresh3/63446c7ce7e65eed0f216888e66ce79f to your computer and use it in GitHub Desktop.

Revisions

  1. andresh3 revised this gist Oct 24, 2023. 2 changed files with 5 additions and 4 deletions.
    4 changes: 1 addition & 3 deletions Version 2.md
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,4 @@
    These bookmarklet's strip down github gist pages so that the content is easily printable.

    This version completely strips the page. (Both versions published 10/23/23, feel free to redist as you please)
    This version completely strips the page.

    ```javascript
    javascript:(function(){var n=document.getElementsByClassName('Box-body')[0].cloneNode(true);document.body.children[0].remove();document.body.appendChild(node);node.style.borderBottom = 'none';})();```
    5 changes: 4 additions & 1 deletion version 1.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,7 @@
    This version leaves some of the header and border-lines.

    ```javascript
    javascript:(function(){document.getElementsByClassName('pagehead')[0].remove();document.getElementsByClassName('js-header-wrapper')[0].remove();})();```
    javascript:(function(){document.getElementsByClassName('pagehead')[0].remove();document.getElementsByClassName('js-header-wrapper')[0].remove();})();
    ```

    These bookmarklet's strip down github gist pages so that the content is easily printable. (Both versions published 10/23/23, feel free to redist as you please). They're not perfect and only work for markdown or other gist pages w/ no horizontal scrolling content and will only do _one_ file and not multiple.
  2. andresh3 revised this gist Oct 24, 2023. 2 changed files with 4 additions and 2 deletions.
    3 changes: 2 additions & 1 deletion Version 2.md
    Original file line number Diff line number Diff line change
    @@ -2,4 +2,5 @@ These bookmarklet's strip down github gist pages so that the content is easily p

    This version completely strips the page. (Both versions published 10/23/23, feel free to redist as you please)

    ```js javascript:(function(){var n=document.getElementsByClassName('Box-body')[0].cloneNode(true);document.body.children[0].remove();document.body.appendChild(node);node.style.borderBottom = 'none';})();```
    ```javascript
    javascript:(function(){var n=document.getElementsByClassName('Box-body')[0].cloneNode(true);document.body.children[0].remove();document.body.appendChild(node);node.style.borderBottom = 'none';})();```
    3 changes: 2 additions & 1 deletion version 1.md
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,4 @@
    This version leaves some of the header and border-lines.

    ```js javascript:(function(){document.getElementsByClassName('pagehead')[0].remove();document.getElementsByClassName('js-header-wrapper')[0].remove();})();```
    ```javascript
    javascript:(function(){document.getElementsByClassName('pagehead')[0].remove();document.getElementsByClassName('js-header-wrapper')[0].remove();})();```
  3. andresh3 created this gist Oct 24, 2023.
    5 changes: 5 additions & 0 deletions Version 2.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    These bookmarklet's strip down github gist pages so that the content is easily printable.

    This version completely strips the page. (Both versions published 10/23/23, feel free to redist as you please)

    ```js javascript:(function(){var n=document.getElementsByClassName('Box-body')[0].cloneNode(true);document.body.children[0].remove();document.body.appendChild(node);node.style.borderBottom = 'none';})();```
    3 changes: 3 additions & 0 deletions version 1.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    This version leaves some of the header and border-lines.

    ```js javascript:(function(){document.getElementsByClassName('pagehead')[0].remove();document.getElementsByClassName('js-header-wrapper')[0].remove();})();```