A JavaScript library for querying and manipulating object properties using expressive paths with wildcards, regexps, slices, and unions.
wild-wild-path is a JavaScript library that enables advanced querying and manipulation of object properties using expressive path syntax. It solves the problem of accessing nested data structures by supporting wildcards, regular expressions, array slices, and unions, going beyond basic dot notation. This makes it particularly useful for dynamic data traversal, configuration management, and complex object transformations.
JavaScript and TypeScript developers working with dynamic or deeply nested objects, such as those building configuration systems, data transformation pipelines, or CLI tools that require flexible property access.
Developers choose wild-wild-path for its rich feature set beyond standard property access libraries, offering regexp matching, wildcard recursion, and union queries in a performant, well-typed package. Its dual query formats (strings for simplicity, arrays for security) and configurable options provide both expressiveness and safety against injection attacks.
🤠 Object property paths with wildcards and regexps 🌵
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Supports wildcards (*, **), regexps, array slices, and unions, enabling complex pattern matching beyond basic dot notation, as shown in the README examples for dynamic data traversal.
Offers array-based queries to prevent injection attacks, recommended for dynamic or user-provided input, enhancing safety in programmatic usage.
Provides a 'mutate' option to choose between immutable deep cloning or direct mutation, balancing safety and performance for object manipulations.
Includes options like 'entries', 'missing', 'sort', and 'childFirst' for precise control over query results, detailed in the README's options section.
Requires ES modules (import statements) and Node.js >=18.18.0, making it incompatible with older CommonJS setups without adjustments.
Symbol properties are always ignored, limiting use with modern JavaScript patterns that rely on symbols for private or unique keys.
With multiple methods and numerous options, the learning curve can be steep for simple use cases, potentially overwhelming new users.