Skip to content

Commit

Permalink
JSHint headless-ember
Browse files Browse the repository at this point in the history
- Mark all exported vars
- Mark redefined global vars
- Suppress leak warning for the redefinition of jQuery
  • Loading branch information
nschonni committed Mar 11, 2014
1 parent 3782fbe commit 9f8d608
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 0 additions & 1 deletion .jshintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
app/assets/javascripts/defer/html-sanitizer-bundle.js
lib/headless-ember.js
lib/javascripts/locale/
lib/javascripts/messageformat.js
lib/javascripts/moment.js
Expand Down
4 changes: 4 additions & 0 deletions lib/headless-ember.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
/*global Element:true, document:true, window:true, $:true, jQuery:true */
/*exported precompileEmberHandlebars, $, jQuery */
// DOM
var Element = {};
Element.firstChild = function () { return Element; };
Expand All @@ -11,8 +13,10 @@ this.document = document;
var console = window.console = {};
console.log = console.info = console.warn = console.error = function(){};

/*jshint -W120 */
// jQuery
var $ = jQuery = window.jQuery = function() { return jQuery; };
/*jshint +W120*/
jQuery.ready = function() { return jQuery; };
jQuery.inArray = function() { return jQuery; };
jQuery.event = {
Expand Down

0 comments on commit 9f8d608

Please sign in to comment.