Skip to content

Commit 1dc0b1d

Browse files
committed
fix: Correct and align type definitions for rule engine components and options.
1 parent b9ade69 commit 1dc0b1d

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4747

4848
## [Unreleased]
4949

50+
## [1.0.4] - 2025-12-15
51+
52+
### Fixed
53+
54+
- **🐛 accurate Types (Issue #4)**: Fixed multiple type definition mismatches:
55+
- `evaluateExpr` now explicitly returns `EvaluationResult` to support `success` property checking.
56+
- `RuleHelpers` comparison methods (`gte`, `eq`, etc.) now correctly treat `options` as optional.
57+
- `rules.validation` helpers are now strictly defined (no longer "possibly undefined").
58+
- `PathResolver` method `resolvePath` renamed to `resolve` to match implementation.
59+
- Added missing `flags` property to `StringOptions` for use with `regex` operator.
60+
61+
### Changed
62+
63+
- **🧹 Type Alignment**: Removed unsupported options `caseInsensitive` and `trim` from `ComparisonOptions` and `StringOptions` types. These were previously defined in types but not supported by the engine. This change aligns types with the actual "Code as Source of Truth".
64+
- **📝 Config Types**: Added missing `persistence` configuration type for `StatefulRuleEngine`.
65+
5066
## [1.0.2] - 2025-08-20
5167

5268
### Added

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "rule-engine-js",
3-
"version": "1.0.3",
3+
"version": "1.0.4",
44
"description": "A high-performance, secure rule engine with dynamic field comparison support",
55
"main": "dist/index.cjs",
66
"module": "dist/index.esm.js",

0 commit comments

Comments
 (0)