js-lib icon indicating copy to clipboard operation
js-lib copied to clipboard

Standard library for universal (browser/server) javascript

Results 6 js-lib issues
Sort by recently updated
recently updated
newest added

Here is the svg from runBench, png-ified: ![runBench](https://github.com/NaturalCycles/js-lib/assets/53127288/dd4627e4-fb60-4dfb-90a4-0a95263070b3) I think the end result is still clean and readable so I don't see any real downside to it.

In this PR, I showcase one pattern to make `j` immutable: with decorators on every class. Why immutability? To avoid such issues: ```ts export const mySchema = j.object({ ... })...

In this PR, I showcase one pattern to make `j` immutable: with decorators on every method that mutates `this.schema`. Why immutability? To avoid such issues: ```ts export const mySchema =...

I understand the test may be useless 😅 If the types are reverted, it _will_ fail at tsc with a type error though

Helpful type to require one property in a type. Could be used like ``` const changeEntries = dailyEntries.entries.filter( (e): e is RequireProp => !!e.change, ) ``` ...to allow accessing the...

Before anything: Ajv is one of the most badly documented tool relative to how much documentation is actually produced. It is badly worded, confusing. In this PR, ChatGPT and I...