Skip to content

Instantly share code, notes, and snippets.

Avatar

jakub-g jakub-g

View GitHub Profile
@jakub-g
jakub-g / README.md
Last active Nov 3, 2020
.vscode/settings.json to ignore derived folders in vscode which make it dog slow when huge
View README.md
@jakub-g
jakub-g / README.md
Last active Nov 3, 2020
git-branches-sorted-by-date-print-last-commit-message.sh
View README.md

Description

  • prints all local branches, one per line
  • sorted by most recently updated (last commit date); rebased = updated
  • shows last commit date + branch name + (different color) last commit message

Usage:

$ branches # prints all local branches (long output but it's still fast)
@jakub-g
jakub-g / wpt-wishlist.md
Last active Sep 30, 2020
WebPageTest wishlist
View wpt-wishlist.md

1. Re-run the test equivalent which allows changing config

Sometimes I have very elaborate test config which I want to reuse, but slightly change one thing (e.g. add one param to URL). I can easily re-run the test with exact same config, but it's not easy to slightly change config and re-run. You need to re-create the config from scratch by checking multiple checkboxes, and hoping you come up with same exact set of params as before

2. Possibility to redefine the "median run" definition

It's apparently possible to override medianMetric param to tell WPT how to choose the median run. It would be nice to use a custom metric for that (say the first perf entry marked with performance.mark('WptEndMetric')). Maybe it's already possible?

View non-critical-nested-imports.js
// app.js
import { criticalHelper } from './utils.js'
let foo = criticalHelper();
// utils.js
import { nestedHelper } from './nested_helper.js'
export function criticalHelper() {/*...*/}
export function otherHelper(str) {
// nestedHelper recursively depends on 5k of code
@jakub-g
jakub-g / README.md
Last active Jun 2, 2020
Deprecation Dailymotion postMessage API
View README.md

Context

If you landed on this page, you probably found a message like this in your logs:

This page is using deprecated Dailymotion postMessage API communication format that will be soon removed.
Please update your code. See https://gist.github.com/jakub-g/89613ccf35a98577ab9c8b9f20955eab for details.

Two possibilities

@jakub-g
jakub-g / loggers.txt
Created May 29, 2020
Filter out annoying loggers Chrome DevTools
View loggers.txt
-cookie -sourcemap -corb -cors
@jakub-g
jakub-g / _1_index.md
Last active May 16, 2020
Trójka LP3 1998 Kazik
View _1_index.md
@jakub-g
jakub-g / es2016+.md
Last active May 14, 2020
UC browser vs Chromium: Kangax ES2016+ tests
@jakub-g
jakub-g / gist:b7b54852011dfd8d708fa88300452f5a
Created May 12, 2020
Samsung TV browser and Samsung TV webview useragent strings
View gist:b7b54852011dfd8d708fa88300452f5a
Samsung Browser:
----------------
Mozilla/5.0 (SMART-TV; Linux; Tizen 5.0) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/2.2 Chrome/63.0.3239.84 TV Safari/537.36
Mozilla/5.0 (SMART-TV; Linux; Tizen 4.0) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/2.1 Chrome/56.0.2924.0 TV Safari/537.36
Samsung WebView:
----------------
Mozilla/5.0 (SMART-TV; LINUX; Tizen 5.0) AppleWebKit/537.36 (KHTML, like Gecko) Version/5.0 TV Safari/537.36
You can’t perform that action at this time.