How to modify the composer package in laravel?

I wrote a composer package before;

Today, I have some new ideas and want to make some changes; you know, things in the vendor folder can"t be changed, so how should I modify a composer package?

< hr >

my idea: first clone this package from github to another folder, and then modify it. After the change, push to github, and then pull it from github to laravel. Run to see the effect. If you have any problems, recycle the above?

is this too complicated? Find the right method

May.09,2021

in view of what you said, you should want to extend and modify the existing composer package. Laravel is managed by dependent packages based on composer, so basically, in your case, you need to modify the package source code and submit it to Packagist and then install it through composer. Specifically, you can refer to the article https://www.jianshu.com/p/ecb.


idea 1, whether inheriting classes can be extended
idea 2, the new package release you mentioned and then introduce
idea 3, release automatic deployment adjustment part
idea 4, tripartite package directory for version management. It has the same meaning as the three.

Menu