@thi.ng/errors 2.0.4 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +82 -69
  2. package/README.md +1 -1
  3. package/package.json +85 -79
package/CHANGELOG.md CHANGED
@@ -1,111 +1,124 @@
1
1
  # Change Log
2
2
 
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [2.0.4](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@2.0.3...@thi.ng/errors@2.0.4) (2021-10-25)
7
-
8
-
9
- ### Bug Fixes
10
-
11
- * [#324](https://github.com/thi-ng/umbrella/issues/324) update snowpack issue workaround ([6dfbf71](https://github.com/thi-ng/umbrella/commit/6dfbf7120faaea7ef6af4f755e1a609cb49d902a)), closes [snowpackjs/snowpack#3621](https://github.com/snowpackjs/snowpack/issues/3621)
12
-
13
-
14
-
15
-
16
-
17
- ## [2.0.3](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@2.0.2...@thi.ng/errors@2.0.3) (2021-10-15)
18
-
19
- **Note:** Version bump only for package @thi.ng/errors
3
+ - **Last updated**: 2021-11-21T17:09:28Z
4
+ - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
20
5
 
6
+ All notable changes to this project will be documented in this file.
7
+ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelines.
21
8
 
9
+ **Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
10
+ and/or version bumps of transitive dependencies.
22
11
 
12
+ ## [2.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@2.1.0) (2021-11-17)
23
13
 
14
+ #### 🚀 Features
24
15
 
25
- ## [2.0.2](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@2.0.1...@thi.ng/errors@2.0.2) (2021-10-15)
26
-
27
- **Note:** Version bump only for package @thi.ng/errors
28
-
29
-
30
-
31
-
32
-
33
- ## [2.0.1](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@2.0.0...@thi.ng/errors@2.0.1) (2021-10-13)
34
-
35
- **Note:** Version bump only for package @thi.ng/errors
36
-
37
-
38
-
16
+ - Using workspaces for local tools ([bf7a404](https://github.com/thi-ng/umbrella/commit/bf7a404))
17
+ Improving the overall build ergonomics
18
+ - introduced a tools workspaces
19
+ - imported it in all needed packages/examples
20
+ - inclusive project root
39
21
 
22
+ #### ♻️ Refactoring
40
23
 
41
- # [2.0.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@1.3.4...@thi.ng/errors@2.0.0) (2021-10-12)
24
+ - testrunner to binary ([4ebbbb2](https://github.com/thi-ng/umbrella/commit/4ebbbb2))
25
+ this commit reverts (partly) changes made in:
26
+ ef346d7a8753590dc9094108a3d861a8dbd5dd2c
27
+ overall purpose is better testament ergonomics:
28
+ instead of having to pass NODE_OPTIONS with every invocation
29
+ having a binary to handle this for us.
42
30
 
31
+ ### [2.0.4](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@2.0.4) (2021-10-25)
43
32
 
44
- ### Build System
33
+ #### 🩹 Bug fixes
45
34
 
46
- * major update of ALL pkgs (export maps, ESM only) ([0d1d6ea](https://github.com/thi-ng/umbrella/commit/0d1d6ea9fab2a645d6c5f2bf2591459b939c09b6))
35
+ - [#324](https://github.com/thi-ng/umbrella/issues/324) update snowpack issue workaround ([6dfbf71](https://github.com/thi-ng/umbrella/commit/6dfbf71))
36
+ - switch to another temp workaround until snowpack team
37
+ fixes snowpackjs/snowpack[#3621](https://github.com/thi-ng/umbrella/issues/3621)
47
38
 
39
+ ### [2.0.1](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@2.0.1) (2021-10-13)
48
40
 
49
- ### Features
41
+ #### ♻️ Refactoring
50
42
 
51
- * **errors:** add snowpack env var support for assert ([52822b1](https://github.com/thi-ng/umbrella/commit/52822b18160949a0a1eefa82e5e667cd0811cd89))
52
- * **errors:** migrate assert() from thi.ng/api ([7030a6a](https://github.com/thi-ng/umbrella/commit/7030a6aecd50367cbc08bccb13e05b3af41f4eca))
43
+ - update imports in all tests/pkgs ([effd591](https://github.com/thi-ng/umbrella/commit/effd591))
44
+ - update imports in all pkgs ([5fa2b6f](https://github.com/thi-ng/umbrella/commit/5fa2b6f))
45
+ - add .js suffix for all relative imports
53
46
 
47
+ # [2.0.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@2.0.0) (2021-10-12)
54
48
 
55
- ### BREAKING CHANGES
49
+ #### 🛑 Breaking changes
56
50
 
57
- * discontinue CommonJS & UMD versions
51
+ - major update of ALL pkgs (export maps, ESM only) ([0d1d6ea](https://github.com/thi-ng/umbrella/commit/0d1d6ea))
52
+ - BREAKING CHANGE: discontinue CommonJS & UMD versions
53
+ - only ESM modules will be published from now on
54
+ - CJS obsolete due to ESM support in recent versions of node:
55
+ - i.e. launch NodeJS via:
56
+ - `node --experimental-specifier-resolution=node --experimental-repl-await`
57
+ - in the node REPL use `await import(...)` instead of `require()`
58
+ - UMD obsolete due to widespread browser support for ESM
59
+ Also:
60
+ - normalize/restructure/reorg all package.json files
61
+ - cleanup all build scripts, remove obsolete
62
+ - switch from mocha to [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament) for all tests
58
63
 
59
- - only ESM modules will be published from now on
60
- - CJS obsolete due to ESM support in recent versions of node:
61
- - i.e. launch NodeJS via:
62
- - `node --experimental-specifier-resolution=node --experimental-repl-await`
63
- - in the node REPL use `await import(...)` instead of `require()`
64
- - UMD obsolete due to widespread browser support for ESM
64
+ #### 🚀 Features
65
65
 
66
- Also:
67
- - normalize/restructure/reorg all package.json files
68
- - cleanup all build scripts, remove obsolete
69
- - switch from mocha to @thi.ng/testament for all tests
66
+ - add snowpack env var support for assert ([52822b1](https://github.com/thi-ng/umbrella/commit/52822b1))
67
+ - migrate assert() from [@thi.ng/api](https://github.com/thi-ng/umbrella/tree/main/packages/api) ([7030a6a](https://github.com/thi-ng/umbrella/commit/7030a6a))
68
+ - add existing assert() fn from api pkg
69
+ - add AssertionError class
70
+ - update pkg
70
71
 
72
+ #### ♻️ Refactoring
71
73
 
74
+ - set string as default generic ([936a9d7](https://github.com/thi-ng/umbrella/commit/936a9d7))
75
+ - update all test stubs ([f2d6d53](https://github.com/thi-ng/umbrella/commit/f2d6d53))
76
+ - update all tests in _all_ pkgs ([8b582bc](https://github.com/thi-ng/umbrella/commit/8b582bc))
77
+ - update all to use [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament)
72
78
 
79
+ ## [1.3.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@1.3.0) (2021-03-17)
73
80
 
81
+ #### 🚀 Features
74
82
 
83
+ - add ensureIndex2(), update outOfBounds() arg type ([ab007d6](https://github.com/thi-ng/umbrella/commit/ab007d6))
84
+ - add outOfBounds(), ensureIndex() ([fb5ca0a](https://github.com/thi-ng/umbrella/commit/fb5ca0a))
75
85
 
76
- # [1.3.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@1.2.32...@thi.ng/errors@1.3.0) (2021-03-17)
86
+ ## [1.2.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@1.2.0) (2019-08-21)
77
87
 
78
- ### Features
88
+ #### 🚀 Features
79
89
 
80
- - **errors:** add ensureIndex2(), update outOfBounds() arg type ([ab007d6](https://github.com/thi-ng/umbrella/commit/ab007d6b502c3d1650c7e9cf50da05f0ac042ef3))
81
- - **errors:** add outOfBounds(), ensureIndex() ([fb5ca0a](https://github.com/thi-ng/umbrella/commit/fb5ca0a7f8a4a6648d3c8485a9108e9154ee4400))
90
+ - add defError(), refactor all existing, update readme ([ded89c2](https://github.com/thi-ng/umbrella/commit/ded89c2))
82
91
 
83
- # [1.2.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@1.1.2...@thi.ng/errors@1.2.0) (2019-08-21)
92
+ ## [1.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@1.1.0) (2019-07-07)
84
93
 
85
- ### Features
94
+ #### 🚀 Features
86
95
 
87
- - **errors:** add defError(), refactor all existing, update readme ([ded89c2](https://github.com/thi-ng/umbrella/commit/ded89c2))
96
+ - enable TS strict compiler flags (refactor) ([8460aea](https://github.com/thi-ng/umbrella/commit/8460aea))
88
97
 
89
- # [1.1.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@1.0.6...@thi.ng/errors@1.1.0) (2019-07-07)
98
+ # [1.0.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@1.0.0) (2019-01-21)
90
99
 
91
- ### Features
100
+ #### 🛑 Breaking changes
92
101
 
93
- - **errors:** enable TS strict compiler flags (refactor) ([8460aea](https://github.com/thi-ng/umbrella/commit/8460aea))
102
+ - update package build scripts & outputs, imports in ~50 packages ([b54b703](https://github.com/thi-ng/umbrella/commit/b54b703))
103
+ - BREAKING CHANGE: enabled multi-outputs (ES6 modules, CJS, UMD)
104
+ - build scripts now first build ES6 modules in package root, then call
105
+ `scripts/bundle-module` to build minified CJS & UMD bundles in `/lib`
106
+ - all imports MUST be updated to only refer to package level
107
+ (not individual files anymore). tree shaking in user land will get rid of
108
+ all unused imported symbols.
94
109
 
95
- # [1.0.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/errors@0.1.12...@thi.ng/errors@1.0.0) (2019-01-21)
110
+ #### ♻️ Refactoring
96
111
 
97
- ### Build System
112
+ - use arrow fns ([d9f4bd3](https://github.com/thi-ng/umbrella/commit/d9f4bd3))
98
113
 
99
- - update package build scripts & outputs, imports in ~50 packages ([b54b703](https://github.com/thi-ng/umbrella/commit/b54b703))
114
+ ### [0.1.1](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@0.1.1) (2018-05-10)
100
115
 
101
- ### BREAKING CHANGES
116
+ #### ♻️ Refactoring
102
117
 
103
- - enabled multi-outputs (ES6 modules, CJS, UMD)
104
- - build scripts now first build ES6 modules in package root, then call `scripts/bundle-module` to build minified CJS & UMD bundles in `/lib`
105
- - all imports MUST be updated to only refer to package level (not individual files anymore). tree shaking in user land will get rid of all unused imported symbols.
118
+ - update return types (`never`) ([5227dd1](https://github.com/thi-ng/umbrella/commit/5227dd1))
106
119
 
107
- # 0.1.0 (2018-05-10)
120
+ ## [0.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/errors@0.1.0) (2018-05-10)
108
121
 
109
- ### Features
122
+ #### 🚀 Features
110
123
 
111
- - **errors:** add new package [@thi](https://github.com/thi).ng/errors ([1e97856](https://github.com/thi-ng/umbrella/commit/1e97856))
124
+ - add new package [@thi.ng/errors](https://github.com/thi-ng/umbrella/tree/main/packages/errors) ([1e97856](https://github.com/thi-ng/umbrella/commit/1e97856))
package/README.md CHANGED
@@ -63,7 +63,7 @@ node --experimental-repl-await
63
63
  > const errors = await import("@thi.ng/errors");
64
64
  ```
65
65
 
66
- Package sizes (gzipped, pre-treeshake): ESM: 538 bytes
66
+ Package sizes (gzipped, pre-treeshake): ESM: 554 bytes
67
67
 
68
68
  ## Dependencies
69
69
 
package/package.json CHANGED
@@ -1,88 +1,94 @@
1
1
  {
2
- "name": "@thi.ng/errors",
3
- "version": "2.0.4",
4
- "description": "Custom error types and error factory functions",
5
- "type": "module",
6
- "module": "./index.js",
7
- "typings": "./index.d.ts",
8
- "sideEffects": false,
9
- "repository": {
10
- "type": "git",
11
- "url": "https://github.com/thi-ng/umbrella.git"
2
+ "name": "@thi.ng/errors",
3
+ "version": "2.1.2",
4
+ "description": "Custom error types and error factory functions",
5
+ "type": "module",
6
+ "module": "./index.js",
7
+ "typings": "./index.d.ts",
8
+ "sideEffects": false,
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/thi-ng/umbrella.git"
12
+ },
13
+ "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/errors#readme",
14
+ "funding": [
15
+ {
16
+ "type": "github",
17
+ "url": "https://github.com/sponsors/postspectacular"
12
18
  },
13
- "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/errors#readme",
14
- "funding": [
15
- {
16
- "type": "github",
17
- "url": "https://github.com/sponsors/postspectacular"
18
- },
19
- {
20
- "type": "patreon",
21
- "url": "https://patreon.com/thing_umbrella"
22
- }
23
- ],
24
- "author": "Karsten Schmidt <k+npm@thi.ng>",
25
- "license": "Apache-2.0",
26
- "scripts": {
27
- "build": "yarn clean && tsc --declaration",
28
- "clean": "rimraf *.js *.d.ts *.map doc",
29
- "doc": "typedoc --excludePrivate --excludeInternal --out doc src/index.ts",
30
- "doc:ae": "mkdir -p .ae/doc .ae/temp && node_modules/.bin/api-extractor run --local --verbose",
31
- "doc:readme": "yarn doc:stats && ../../scripts/node-esm ../../tools/src/readme.ts",
32
- "doc:stats": "../../scripts/node-esm ../../tools/src/module-stats.ts",
33
- "pub": "yarn build && yarn publish --access public",
34
- "test": "testament test"
19
+ {
20
+ "type": "patreon",
21
+ "url": "https://patreon.com/thing_umbrella"
22
+ }
23
+ ],
24
+ "author": "Karsten Schmidt <k+npm@thi.ng>",
25
+ "license": "Apache-2.0",
26
+ "scripts": {
27
+ "build": "yarn clean && tsc --declaration",
28
+ "clean": "rimraf '*.js' '*.d.ts' '*.map' doc",
29
+ "doc": "typedoc --excludePrivate --excludeInternal --out doc src/index.ts",
30
+ "doc:ae": "mkdir -p .ae/doc .ae/temp && api-extractor run --local --verbose",
31
+ "doc:readme": "yarn doc:stats && tools:readme",
32
+ "doc:stats": "tools:module-stats",
33
+ "pub": "yarn npm publish --access public",
34
+ "test": "testament test"
35
+ },
36
+ "devDependencies": {
37
+ "@microsoft/api-extractor": "^7.18.19",
38
+ "@thi.ng/testament": "^0.2.2",
39
+ "@types/node": "^16.11.7",
40
+ "rimraf": "^3.0.2",
41
+ "tools": "^0.0.1",
42
+ "typedoc": "^0.22.9",
43
+ "typescript": "^4.5.2"
44
+ },
45
+ "keywords": [
46
+ "assert",
47
+ "error",
48
+ "typescript"
49
+ ],
50
+ "publishConfig": {
51
+ "access": "public"
52
+ },
53
+ "browser": {
54
+ "process": false,
55
+ "setTimeout": false
56
+ },
57
+ "engines": {
58
+ "node": ">=12.7"
59
+ },
60
+ "files": [
61
+ "*.js",
62
+ "*.d.ts"
63
+ ],
64
+ "exports": {
65
+ ".": {
66
+ "import": "./index.js"
35
67
  },
36
- "devDependencies": {
37
- "@thi.ng/testament": "^0.1.4"
68
+ "./assert": {
69
+ "import": "./assert.js"
38
70
  },
39
- "keywords": [
40
- "assert",
41
- "error",
42
- "typescript"
43
- ],
44
- "publishConfig": {
45
- "access": "public"
71
+ "./deferror": {
72
+ "import": "./deferror.js"
46
73
  },
47
- "browser": {
48
- "process": false,
49
- "setTimeout": false
74
+ "./illegal-arguments": {
75
+ "import": "./illegal-arguments.js"
50
76
  },
51
- "engines": {
52
- "node": ">=12.7"
77
+ "./illegal-arity": {
78
+ "import": "./illegal-arity.js"
53
79
  },
54
- "files": [
55
- "*.js",
56
- "*.d.ts"
57
- ],
58
- "exports": {
59
- ".": {
60
- "import": "./index.js"
61
- },
62
- "./assert": {
63
- "import": "./assert.js"
64
- },
65
- "./deferror": {
66
- "import": "./deferror.js"
67
- },
68
- "./illegal-arguments": {
69
- "import": "./illegal-arguments.js"
70
- },
71
- "./illegal-arity": {
72
- "import": "./illegal-arity.js"
73
- },
74
- "./illegal-state": {
75
- "import": "./illegal-state.js"
76
- },
77
- "./out-of-bounds": {
78
- "import": "./out-of-bounds.js"
79
- },
80
- "./unsupported": {
81
- "import": "./unsupported.js"
82
- }
80
+ "./illegal-state": {
81
+ "import": "./illegal-state.js"
83
82
  },
84
- "thi.ng": {
85
- "year": 2018
83
+ "./out-of-bounds": {
84
+ "import": "./out-of-bounds.js"
86
85
  },
87
- "gitHead": "9ff00a103f76cc4917ef3f244132e218f2300a05"
88
- }
86
+ "./unsupported": {
87
+ "import": "./unsupported.js"
88
+ }
89
+ },
90
+ "thi.ng": {
91
+ "year": 2018
92
+ },
93
+ "gitHead": "e8a7c2a40191b391cef182c2978e5a6c85987a87\n"
94
+ }