{"repo":"GoogleChromeLabs/css-selector-benchmark","free":true,"listed":false,"github":"https://github.com/GoogleChromeLabs/css-selector-benchmark","clone":"git clone https://github.com/GoogleChromeLabs/css-selector-benchmark.git","description":"CSS Selector Benchmarks, using PerfTestRunner and Puppeteer","language":"HTML","stars":25,"topics":["css","performance","puppeteer"],"license":"Apache-2.0","category":"scrapers-browser-automation","readme_excerpt":"CSS Selector Benchmark CSS Selector Benchmarks, using PerfTestRunner and Puppeteer Prerequisites Project Setup Install dependencies Install browsers to test with Start the web server The benchmarks are HTML pages which need to be served by a web server The Web Server is now running at http://localhost:3000/ Running a benchmark With the Web Server running, invoke a benchmark on the CLI: This will run the benchmark served by http://localhost:3000/benchmarks/example/ , whose source is located at ./src/benchmarks/example/index.html Note: You can also run benchmarks directly in a browser. To do so, visit its URL and invoke window.startTest().then(console.table); on the Console. Choosing which browser to run the benchmarks in To select which browser to test things in, use the --browser option. Supported options: - chrome = Use Chrome - chrome = Use Chrome Stable - chrome-beta = Use Chrome Beta - chrome-dev = Use Chrome Dev - chrome-canary = Use Chrome Canary - firefox = Use Firefox The default used browser is chrome . A note will be printed on screen to show which version you are using. For example: Creating a benchmark Benchmarks are HTML pages stored in a subfolder in ./src/benchmarks/ . The page MUST expose a window.startTest method which returns a promise. When the test logic is done, it MUST resolve that promise. This window.startTest is automatically invoked by npm run benchmark x when the page has loaded. Once window.startTest has resolved, the benchmark will be closed and a","default_branch":null,"files":null,"tree":[],"storefront":"/r/GoogleChromeLabs","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/GoogleChromeLabs/css-selector-benchmark/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}