| Name | Calculation |
|---|---|
| Radius (RD) | input (px) |
| Stroke (STR) | input (px) |
| Normalized Radius (NRD) | RD - STR * 2 |
| Circumference (CIRC) | NR * 2 * π |
| Border Part Percent (BPP) | input |
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 smallArray: string[] = []; // initial value IDK? | |
| // unless you need to update the array itself, you can leave with the set. | |
| // If you need to update the array, you can do that close to actions on the set. | |
| const smallSet = new Set<string>(smallArray); | |
| addEventListener('new-array-to-compare', (bigArray: string[]) => { | |
| for (const value of bigArray) { | |
| if (smallSet.delete(value)) { | |
| // value was in smallSet and was deleted |
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
| [ | |
| null, | |
| null, | |
| [4], | |
| [26], | |
| 1617712224719887, | |
| "AODP23YAAAAiUiAIHRCA6NzY_-fvAhj_p7rHwervAjoKCJqUgdaP_fWPZYKq8GJhyNufIGMobYdaxGb11CPJ", | |
| "AODP23YAAAATChEIzQEQl9uUJBiPqIPUz-nvAvgaUiH-QF1r6sbp1CQSdAdoe2ac", | |
| [ | |
| "YouTube", |
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
| import {isObservableMap, isObservableSet} from 'mobx'; | |
| interface Adapter { | |
| is: (value: unknown) => boolean; | |
| serialize: (value: any) => any; | |
| deserialize: (value: any) => any; | |
| } | |
| const spread = (value: any) => [...value]; |
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
| import {isObservableMap, isObservableSet, observable} from 'mobx'; | |
| const DATA_TYPE_FIELD = '___jsonDataType'; | |
| function getCollectionTypeName(value: any): 'Set' | 'Map' | 'ObservableSet' | 'ObservableMap' | undefined { | |
| if (isObservableMap(value)) { | |
| return 'ObservableMap'; | |
| } | |
| if (isObservableSet(value)) { | |
| return 'ObservableSet'; | |
| } |
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
| import { defer, NEVER, Subject, throwError } from "rxjs"; | |
| import { | |
| bufferTime, | |
| catchError, | |
| filter, | |
| mapTo, | |
| mergeMap, | |
| retry, | |
| // tap, | |
| } from "rxjs/operators"; |
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
| version: '1.0' | |
| kind: pipeline | |
| metadata: | |
| name: my-website/publish | |
| project: my-website | |
| spec: | |
| triggers: | |
| - name: master_commit |
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
| ... |
Link: https://www.youtube.com/watch?v=fjYAU3jayVo
Great talk by Yuri Shkuro from Uber, which is highly involved in the world of tracing,
Has worked a lot on OpenTracing (the standard for tracing apis), and Jaeger in particular (the tool we're using).
Github Repo: https://github.com/yurishkuro/opentracing-tutorial
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
| class Component { | |
| data$ = this.service.getData(); | |
| constructor(private service: Service) { } | |
| } | |
| class Component { | |
| data$: Observable<Data>; | |
| constructor(private service: Service) { | |
| this.data$ = service.getData(); |