https://github.com/peterboyer/peterboyer
https://github.com/peterboyer/peterboyer
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/peterboyer/peterboyer
- Owner: peterboyer
- Created: 2022-04-22T00:43:18.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2025-05-21T13:40:42.000Z (about 1 year ago)
- Last Synced: 2025-07-23T15:58:09.609Z (about 1 year ago)
- Size: 17.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
- use tabs for indentation (dev accessibility) [1](https://www.reddit.com/r/javascript/comments/c8drjo/nobody_talks_about_the_real_reason_to_use_tabs/) [2](https://github.com/prettier/prettier/issues/7475/)
- typescript: use `type` unless you _need_ `interface` features (e.g. declaration merging) [1](ttps://www.youtube.com/watch?v=zM9UPcIyyhQ)
- typescript: use explicit `function` return types (clear intent, faster tsc, reduced inference) [1](https://twitter.com/jon_dewitt_ts/status/1620988514317004801?s=20&t=Jj2idhGSt4oBpeYOIQ3-uQ) [2](https://twitter.com/ThePrimeagen/status/1620808334562697217?s=20&t=ZM-gCfYAC2_HQu361Ra2aA)
- typescript: avoid `enum` (only supports string/number values; instead, use objects as const, or try [`pb.adt`](https://github.com/peterboyer/pb.adt)) [1](https://www.youtube.com/watch?v=jjMbPt_H3RQ)
- typescript: avoid `throw` (poor control flow; instead, return error objects, or try [`pb.safe`](https://github.com/peterboyer/pb.safe))