Skip to content

PHP-JS 2.0.0

Latest
Compare
Choose a tag to compare
@EmielBruijntjes EmielBruijntjes released this 18 May 17:37
956eaa7

PHP-JS 2.0.0

This is a major new release of php-js, built on a much newer version of the V8 engine. The previous 1.4.x series was based on a V8 version over a decade old. Upgrading to a modern V8 required a near-complete rewrite of the codebase.

Highlights

Array conversion support
JavaScript arrays are now properly converted to PHP arrays.

Improved iterator support
Iterators work more reliably and consistently across language boundaries.

Better object reuse detection
Improved internal logic avoids returning duplicate PHP representations of the same JS object.

Stronger context isolation
Each JS\Context is better encapsulated and separated from others.

New JS\Script class
Introduced for better handling of compiled scripts.

Upgrade notes

Although we've made a significant internal overhaul to support the latest V8 engine, we've done our best to maintain compatibility with existing usage patterns. That said, due to the size of the upgrade, some scripts may require minor adjustments. Please test thoroughly before rolling out to production.