- Help -> Install New Software
- Add this: http://github.eclipsesource.com/jshint-eclipse/updates/
- Install JSHint. Studio will restart.
After successfull install, right click on your project:
- Properties:
After successfull install, right click on your project:
| { | |
| "bitwise": true, | |
| "camelcase": true, | |
| "eqeqeq": true, | |
| "newcap": true, | |
| "indent": 4, | |
| "unused": true, | |
| "onevar": true, | |
| "undef": true, | |
| "trailing": true, |
| <?xml version="1.0"?> | |
| <ruleset name="AG"> | |
| <description>The Coding Standard.</description> | |
| <arg name="tab-width" value="4"/> | |
| <!-- PSR2 --> | |
| <rule ref="PSR2.Classes.PropertyDeclaration"/> | |
| <rule ref="PSR2.ControlStructures.ElseIfDeclaration"/> | |
| <rule ref="PSR2.Files.EndFileNewline"/> | |
| <rule ref="PSR2.Methods.FunctionCallSignature.SpaceAfterCloseBracket"> |
| // http://jsfiddle.net/gerst20051/zhzuwoqe/ | |
| var language = 'swift'; | |
| var how_awesome = 'very awesome!!'; | |
| var string = 'hey i\'m a \\(language) string in disguise. \\(how_awesome)'; | |
| function parseString(data) { | |
| var re = /\\\((.*?)\)/g; | |
| return data.replace(re, function(match) { | |
| return eval(match.replace(/\\/g, '').replace(/\(/g, '').replace(/\)/g, '')); |
| { | |
| "disallowEmptyBlocks": true, | |
| /*"disallowDanglingUnderscores": true,*/ | |
| "disallowKeywords": [ | |
| "with" | |
| ], | |
| "disallowKeywordsOnNewLine": [ | |
| "else" | |
| ], | |
| "disallowMixedSpacesAndTabs": true, |
| { | |
| // JSHint Configuration File | |
| // See http://jshint.com/docs/ for more details | |
| "maxerr" : 50, // {int} Maximum error before stopping | |
| // Enforcing | |
| "bitwise" : true, // true: Prohibit bitwise operators (&, |, ^, etc.) | |
| "camelcase" : false, // true: Identifiers must be in camelCase | |
| "curly" : true, // true: Require {} for every new block or scope |
| var clickIntervalId = setInterval(function () { | |
| $('.js-events-pagination').click(); | |
| }, 2E3); | |
| setTimeout(function () { | |
| clearInterval(clickIntervalId); | |
| $('.news').find('.create, .fork, .public, .issues_opened, .member_add').remove() && | |
| $('.watch_started').find('.title').find('a:eq(1):not(:contains("dynamics.js"))').closest('.watch_started').remove(); | |
| }, 20E3); |
| rules: | |
| indent: | |
| - 2 | |
| - 4 | |
| quotes: | |
| - 2 | |
| - single | |
| linebreak-style: | |
| - 2 | |
| - unix |
| <?php | |
| $permutation = new Permutation(); | |
| // $permutation = new Permutation(array_rand(range(0, 100), 4)); | |
| class Permutation | |
| { | |
| private $data = []; | |
| private $permutations = []; |
| window.Hash = { | |
| query: {}, | |
| getHash: function () { | |
| return decodeURIComponent(window.location.hash.substring(1)); | |
| }, | |
| clearHash: function () { | |
| window.location.replace('#'); | |
| }, | |
| setHash: function (hash) { | |
| window.location.replace('#' + encodeURI(hash)); |