This file has been truncated, but you can view the full file.
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
// The Monaco Editor can be easily created, given an | |
// empty container and an options literal. | |
// Two members of the literal are "value" and "language". | |
// The editor takes the full size of its container. | |
const WarAndPeace = `# 00 - A War and Peace | |
BOOK ONE: 1805 | |
CHAPTER I |
This file has been truncated, but you can view the full file.
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
const bench = ( name, fn ) => { | |
console.time ( name ); | |
fn (); | |
console.timeEnd ( name ); | |
}; | |
const run = () => { | |
const dumb = 'a'.repeat ( 4000000 ).replace ( /[\r\0]/g, '' ); // The seemingly useless regex here makes things go faster later on |
NewerOlder