Skip to content

Instantly share code, notes, and snippets.

View mattzeunert's full-sized avatar

Matt Zeunert mattzeunert

View GitHub Profile
Running "mutationTest:karma" (mutationTest) task
(13:39:07.411) TRACE [mutation-testing-karma]: Copied ["src/add.js","test/add.spec.js"] to /var/folders/tg/r1vq4wwd641fbx971h2gyqp00000gn/T/mutation-testing11579-30295-4zr6ka
(13:39:07.414) TRACE [KarmaServer]: Starting a Karma server on port 12111...
(13:39:07.414) TRACE [KarmaServer]: Server status changed to: INITIALIZING
{ waitForServerTime: 10,
waitForRunnerTime: 2,
waitForCoverageTime: 5,
frameworks: [ 'jasmine' ],
files: [ 'src/add.js', 'test/*.js' ],
logLevel: 'INFO',
Running "mutationTest:karma" (mutationTest) task
(13:40:25.663) TRACE [mutation-testing-karma]: Copied ["src/add.js","test/add.spec.js"] to /var/folders/tg/r1vq4wwd641fbx971h2gyqp00000gn/T/mutation-testing11579-30414-h3y7d7
(13:40:25.665) TRACE [KarmaServer]: Starting a Karma server on port 12111...
(13:40:25.665) TRACE [KarmaServer]: Server status changed to: INITIALIZING
(13:40:26.489) DEBUG [KarmaServer]: 09 08 2015 13:40:26.487:INFO [karma]: Karma v0.13.8 server started at http://localhost:12111/
(13:40:26.493) DEBUG [KarmaServer]: 09 08 2015 13:40:26.492:INFO [launcher]: Starting browser Chrome
(13:40:27.369) DEBUG [KarmaServer]: 09 08 2015 13:40:27.369:INFO [Chrome 44.0.2403 (Mac OS X 10.10.4)]: Connected on socket A31K__dwf5_um9AzAAAA with id 10769986
begin_compilation
name "add"
method "add:0"
date 1440029178000
end_compilation
begin_cfg
name "H_Assign dominators"
begin_block
name "B0"
from_bci -1
--- Raw source ---
function add(a, b){
return a + b;
}
print(add(15, 19));
for (var i=0;i<1000;i++){
add(i, 22);
}
var REPEATS = 1000;
var _add = function (n1, n2) {
return n1 + n2;
}
a = 4;
b = 5;
var alternatives = [
{
function getLevelIndentation(level){
return level * 20 + "px";
}
window.devtoolsFormatters = [{
header: function(obj, config){
if (config && config.backboneModelFormatter){
return ["div", {}, config.key]
}
if (!(obj instanceof Backbone.Model)){

Ran a test where I have a location in some minified code, then prettify that code and want to know the new location:

1154.107ms prettier formatWithCursor
 299.370ms pretty-fast (initial)
  25.215ms pretty-fast (cached source map)

Downsides of pretty-fast:

  • doesn't seem to support column-level mapping
var request = require("request");
app.get("/weather/:cityId", (req, res) => {
request("http://weatherapithing.com/" + req.params.cityId, function(
error,
response,
body
) {
console.log("error:", error); // Print the error if one occurred
res.header("Access-Control-Allow-Origin", "*");
var FINGER_SIZE_PX = 48;
var checkOverlapBetweenFingers = false
var scoreBasedOnOverlapArea = true
function simplifyBCRs(bcrs) {
bcrs = bcrs.filter(bcr => {
console.time("start")
var FINGER_SIZE_PX = 48;
// var checkOverlapBetweenFingers = false
// var scoreBasedOnOverlapArea = true
/**
* Merge client rects together and remove small ones. This may result in a larger overall