<commit_before>var page = require('webpage').create();

page.viewportSize = page.clipRect = { 
    width: 1024, height: 768
};

var name = 'github.explore.';
name += ~~(Math.random() * 1e3) + '.png';

page.open('http://github.com/explore', function() {
    
    // super idomatic
    page.clipRect = page.evaluate(function() {
        var selector = '.featured-grid'
        var elem = document.querySelector(selector);
        return elem.getBoundingClientRect();
    });

    page.render(name);
    phantom.exit();
});<commit_msg>shorter element capture<commit_after>var page = require('webpage').create();

page.open('http://github.com/explore', function() {
    
    // super idomatic
    page.clipRect = page.evaluate(function() {
        var selector = '.featured-grid'
        var elem = document.querySelector(selector);
        return elem.getBoundingClientRect();
    });

    page.render('github.explore.' + Math.random() + ".png");
    phantom.exit();
});
{'fraction_non_alphanumeric': 0.17269906928645296, 'fraction_numerical': 0.009307135470527405, 'mean_word_length': 3.1545064377682404, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '383446', 'n_tokens_mistral': 310, 'n_tokens_neox': 293, 'n_words': 55}