Install https://nubjs.com/
Install https://cli.github.com/
gh extension install github/gh-stackInstall https://nubjs.com/
Install https://cli.github.com/
gh extension install github/gh-stack| .\scrcpy.exe --new-display=2720x1280/192 | |
| .\adb.exe shell dumpsys display | Select-String mDisplayId | |
| .\adb.exe shell dumpsys window | Select-String mFocusedApp | |
| .\adb.exe shell am display move-stack <focusedAppId> <displayId> |
| const a = { foo: "bar" }; | |
| const b = { bar: "foo" }; | |
| const c = { foo: "baz", bar: "baz" }; | |
| // ok - no conflicts | |
| const result1 = merge(a).with(b).commit(); | |
| // @ts-expect-error |
| /** | |
| * Type used to declare a type-safe reducer without switch-cases. | |
| * | |
| * @example | |
| * ```ts | |
| * interface State { | |
| * loading: boolean; | |
| * } | |
| * | |
| * type Action = Readonly< |
| ls | while read file; do convert $file -resize 15% $(echo $file | sed -e 's/\.jpg/_thumb\.jpg/g'); done |
| export default function UserRoutes({ db, jwt }) { | |
| const Validation = ctx => ({ | |
| name: [required(), minLength(2), maxLength(255)], | |
| email: [required(!ctx.body.phone), email(), uniqueUserEmail(db)], | |
| phone: [required(!ctx.body.email), phone(), uniqueUserPhone(db)], | |
| document: [ | |
| required(), | |
| async doc => doc.match(/\d+/) || ValidationErrors.invalid_document | |
| ] | |
| }); |
| import { Dayjs, PluginFunc, ConfigType } from 'dayjs'; | |
| declare const plugin: PluginFunc; | |
| export = plugin; | |
| declare module 'dayjs' { | |
| /** Similar to date-fns/utcToZonedTime */ | |
| function utcToZoned(config: ConfigType, timezone?: string): Dayjs; | |
| /** Similar to date-fns/zonedTimeToUtc */ |
| /** | |
| * @link https://jsperf.com/javascript-string-character-finder/7 | |
| */ | |
| function indexesOf(string, regex) { | |
| var match, | |
| indexes = {}; | |
| regex = new RegExp(regex); | |
| while (match = regex.exec(string)) { |