Div PHP Laze 1.1.0
We're excited to announce the release of Laze v1.1.0, which brings powerful new capabilities and improvements to the library.
Key Features and Changes:
- Support for Closures as Lazy Values: In addition to scalar values and object instances, you can now store closures as lazy values. This means Laze can handle any mixed type, offering greater flexibility in how you define and manage your lazy evaluations.
- Evaluation Tracking with evaluated() Method: Introducing the new
evaluated()
method, which allows you to check whether a lazy value has been materialized (evaluated) or if it remains in its initial state. This provides greater control and insight into the lifecycle of your lazy values. - Clear Differentiation from PHP Constants: We’ve introduced the concept of lazy immutable value to distinguish the library’s functionality from PHP’s native constants. This ensures that users understand these values are not traditional constants but are instead values that, once evaluated, become immutable.
With these enhancements, laze
becomes even more versatile, allowing you to manage a wide variety of lazy values with precision and control. Whether you're dealing with simple scalars, complex objects, or even functions that should be deferred, laze
has you covered.