Giter Club home page Giter Club logo

Comments (3)

JanMikes avatar JanMikes commented on June 15, 2024 1

I know rector and use it regularly on my projects, it is a very good tool for refactoring!

I have read somewhere that there will be a migration tool from Zend to Laminas, I am curious, what tool would you use, or write a new one?

Imho using something that already exists might save you a lot of time 😉

from laminas-zendframework-bridge.

weierophinney avatar weierophinney commented on June 15, 2024

@TomasVotruba and @JanMikes

I'm sorry I didn't see and respond to this earlier. When we pushed the package, we were in the early stages of development.

There is more going on than what you describe, however.

The Laminas packages will act as replacements for the ZF packages. We do not expect there to be a mix of Laminas and ZF packages in a project. However, if there are, we need to do a few things:

  • If a reference is made to a ZF class (such as typehinting on an interface), but the replacement Laminas package is installed, inheritance must still work. As such, the autoloading in this package also creates class_alias statements from the ZF artifacts to the Laminas implementations when they are found, to ensure that inheritance and hinting continues to work.

  • Additionally, with dependency configuration, ::class annotation does not trigger autoloading. As such, this package now also provides configuration post-processing in order to rewrite such references to their Laminas equivalents. (It also identifies known ZF configuration keys and rewrites those.)

And that's just what this tool does. The tool for rewriting repositories does far more, as does the tool for migrating userland code to the new packages.

Rector might have helped, but there's a lot of small edge cases that we were able to identify and handle that we may not have been able to shoe-horn into another tool. That said, if I'd seen this earlier, we might have investigated Rector more closely earlier on.

from laminas-zendframework-bridge.

TomasVotruba avatar TomasVotruba commented on June 15, 2024

No troubles :) Thanks for reaching out 👍

from laminas-zendframework-bridge.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.