Last active
August 10, 2016 13:43
-
-
Save justinobney/b59fa2787ca6f9d222a1 to your computer and use it in GitHub Desktop.
Hacker News - Who is hiring trends
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var clientSide = [ | |
'javascript', | |
'elm', | |
'ember', | |
'angular', | |
'jquery', | |
'backbone', | |
'react', | |
'reactjs', | |
'clojurescript', | |
'typescript', | |
'aurelia' | |
]; | |
var serverSide = [ | |
'C#', | |
'Rust', | |
'GoLang', | |
'Python', | |
'DJango', | |
'Closure', | |
'Ruby', | |
'Haskel', | |
'Swift', | |
'node', | |
'nodeJS', | |
]; | |
var mobile = [ | |
'ios', | |
'android', | |
'React Native', | |
'Swift' | |
]; | |
var comments = document.querySelector('.comment-tree') | |
var source = comments.innerText; | |
console.table(clientSide.map(function(term){ | |
var matches = source.match(new RegExp(term, 'gi')) || []; | |
return {name: term, count: matches.length} | |
})); | |
console.table(serverSide.map(function(term){ | |
var matches = source.match(new RegExp(term, 'gi')) || []; | |
return {name: term, count: matches.length} | |
})); | |
console.table(mobile.map(function(term){ | |
var matches = source.match(new RegExp(term, 'gi')) || []; | |
return {name: term, count: matches.length} | |
})); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment