Skip to content

Commit

Permalink
Add ResultError, refactor panic (#7)
Browse files Browse the repository at this point in the history
* Add result error abstract class

* Add try errors

* Add from, into

* Add stack and name

* Add tsx pkg

* Update vitest

* Add result error tests

* Remove error extends

Apparently it's not easy to built-ins across every environment.

See: https://github.com/Microsoft/TypeScript/wiki/FAQ#why-doesnt-extending-built-ins-like-error-array-and-map-work

* Add stack

* Update ResultError stack

* Add origin name to stack trace

* Remove none value

* Add guardWith

* Add guardWith tests

* Refactor dirs

* Update panic

* Add sideEffects false key to pkg json
  • Loading branch information
bkiac authored Nov 3, 2023
1 parent 4364966 commit f4f1d5d
Show file tree
Hide file tree
Showing 35 changed files with 1,350 additions and 970 deletions.
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,11 @@
"prettier": "^3.0.2",
"prettier-plugin-pkg": "^0.18.0",
"tsup": "^7.2.0",
"tsx": "^3.14.0",
"typescript": "^5.0.4",
"vitest": "^0.31.0"
"vitest": "^0.34.6"
},
"sideEffects": false,
"lint-staged": {
"*.{ts,yaml,json,md}": "prettier --write"
},
Expand Down
Loading

0 comments on commit f4f1d5d

Please sign in to comment.