ansuko 2.0.0 → 2.0.1
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.
- package/CHANGELOG.md +64 -0
- package/package.json +4 -2
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
For changes prior to v2.0.0, see the [git history](https://github.com/sera4am/ansuko/commits/main).
|
|
9
|
+
|
|
10
|
+
## [Unreleased]
|
|
11
|
+
|
|
12
|
+
## [2.0.1] - 2026-05-08
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
- `CHANGELOG.md` based on the [Keep a Changelog](https://keepachangelog.com/) format.
|
|
16
|
+
- `scripts/promote-changelog.sh` and an `npm version` lifecycle hook that
|
|
17
|
+
promotes the `[Unreleased]` section to a versioned heading on every
|
|
18
|
+
release. CHANGELOG updates are bundled into the same commit as the
|
|
19
|
+
version bump automatically.
|
|
20
|
+
- `CLAUDE.md` documenting the release flow, plugin architecture, and
|
|
21
|
+
conventions for future contributors (and for Claude Code sessions).
|
|
22
|
+
|
|
23
|
+
## [2.0.0] - 2026-05-08
|
|
24
|
+
|
|
25
|
+
### Removed (BREAKING)
|
|
26
|
+
- `_.extend(plugin)` API. Plugins are now loaded via side-effect imports
|
|
27
|
+
(`import "ansuko/plugins/ja"`).
|
|
28
|
+
|
|
29
|
+
### Changed (BREAKING)
|
|
30
|
+
- Plugin loading: side-effect imports + TypeScript `declare module` merging.
|
|
31
|
+
IDE autocompletion now works directly on `_` for all plugin methods —
|
|
32
|
+
the previous `_.extend(plugin)` returned a new type but left the original
|
|
33
|
+
`_` reference's type unchanged, so plugin methods never appeared in
|
|
34
|
+
suggestions.
|
|
35
|
+
- `AnsukoType` now extends `Omit<LoDashStatic, "isEmpty" | "toNumber" |
|
|
36
|
+
"castArray" | "extend">` instead of enumerating ~330 lodash methods by
|
|
37
|
+
hand. lodash generics are preserved and `@types/lodash` updates flow
|
|
38
|
+
through automatically.
|
|
39
|
+
|
|
40
|
+
### Added
|
|
41
|
+
- `_.__plugins: Set<string>` registry. Each plugin registers itself once
|
|
42
|
+
and skips re-registration when imported from multiple modules.
|
|
43
|
+
|
|
44
|
+
### Migration
|
|
45
|
+
|
|
46
|
+
```ts
|
|
47
|
+
// v1
|
|
48
|
+
import _ from "ansuko"
|
|
49
|
+
import jaPlugin from "ansuko/plugins/ja"
|
|
50
|
+
const ansuko = _.extend(jaPlugin)
|
|
51
|
+
ansuko.kanaToFull("ガ")
|
|
52
|
+
|
|
53
|
+
// v2
|
|
54
|
+
import _ from "ansuko"
|
|
55
|
+
import "ansuko/plugins/ja"
|
|
56
|
+
_.kanaToFull("ガ")
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
If you previously chained `_.extend(a).extend(b)`, replace it with two
|
|
60
|
+
side-effect imports.
|
|
61
|
+
|
|
62
|
+
[Unreleased]: https://github.com/sera4am/ansuko/compare/v2.0.1...HEAD
|
|
63
|
+
[2.0.1]: https://github.com/sera4am/ansuko/releases/tag/v2.0.1
|
|
64
|
+
[2.0.0]: https://github.com/sera4am/ansuko/releases/tag/v2.0.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ansuko",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "A modern JavaScript/TypeScript utility library that extends lodash with practical, intuitive behaviors. Fixes lodash quirks, adds Promise support, Japanese text processing, and GeoJSON utilities.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"lodash",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"files": [
|
|
35
35
|
"dist",
|
|
36
36
|
"README.md",
|
|
37
|
+
"CHANGELOG.md",
|
|
37
38
|
"LICENSE"
|
|
38
39
|
],
|
|
39
40
|
"exports": {
|
|
@@ -48,7 +49,8 @@
|
|
|
48
49
|
"test": "npm run build && vitest run",
|
|
49
50
|
"test:watch": "vitest",
|
|
50
51
|
"typecheck": "tsc --noEmit",
|
|
51
|
-
"lint": "eslint src --ext .ts,.tsx"
|
|
52
|
+
"lint": "eslint src --ext .ts,.tsx",
|
|
53
|
+
"version": "bash ./scripts/promote-changelog.sh && git add CHANGELOG.md"
|
|
52
54
|
},
|
|
53
55
|
"dependencies": {
|
|
54
56
|
"@turf/turf": "^7.3.1",
|