Skip to content

Instantly share code, notes, and snippets.

@et
Last active August 29, 2015 14:23
Show Gist options
  • Select an option

  • Save et/9e0097b36dab65d9ed86 to your computer and use it in GitHub Desktop.

Select an option

Save et/9e0097b36dab65d9ed86 to your computer and use it in GitHub Desktop.

Revisions

  1. et revised this gist Jun 23, 2015. 1 changed file with 9 additions and 3 deletions.
    12 changes: 9 additions & 3 deletions gistfile1.js
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,10 @@
    var _this = this;
    items.forEach(function(item) {
    _this.doSomething(item);
    });


    items.map(function(item) {


    return _this.massageSomething(item);


    });
  2. et revised this gist Jun 23, 2015. 1 changed file with 4 additions and 9 deletions.
    13 changes: 4 additions & 9 deletions gistfile1.js
    Original file line number Diff line number Diff line change
    @@ -1,9 +1,4 @@
    var outsideVariable = "foobar";

    function myFunction() {
    return outsideVariable;
    }

    function myFunction(outsideVariable) {
    return outsideVariable;
    }
    var _this = this;
    items.forEach(function(item) {
    _this.doSomething(item);
    });
  3. et renamed this gist Jun 23, 2015. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  4. et created this gist Jun 23, 2015.
    9 changes: 9 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,9 @@
    var outsideVariable = "foobar";

    function myFunction() {
    return outsideVariable;
    }

    function myFunction(outsideVariable) {
    return outsideVariable;
    }