-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Standalone port? #4
Comments
Hi @flo-sch, Thanks, nice you're interested in this project. I tried to create this minifier with multi framework support in mind. So it should be possible to integrate this project into Symfony too. I used You want to move the ServiceProviders out of this repo and you suggest to create a separate HtmlMinifierLaravel repo?! Possible, but I don't see the value of that right now? Is it needed for Symfony integration (not really a Symfony developer)? I thought it was nice to just have one project with all the source code in mind so you can use it in any project (sure, there is overhead in the sense that you don't need certain source files). I'm open to pull requests and suggestions. Can you answer those questions so we can talk further about how we want to address some issues? |
Hi @ArjanSchouten, thanks for taking the time to answer :) Short story, currently:
Which means I can't use this minifier in a Symfony project using Symfony >= 3.1, for instance 3.3.8 (which I do). It is obviously easily fixable just by updating the composer version of But IMHO this would be a never ending issue, each time one framework dependency would have dependencies updates, the story would start again, which is my main argument for relying in framework-agnostic (or in my case, symfony-dependent plugins). I already started to play a bit and came with a laravel agnostic version of the minifier, without any big problem, Then I was able to use this minifier to minify the output of a symfony I just need to find out what's the best way to handle this with Twig (Symfony default template engine), which code source I'm not that confident with yet, but I'm close to be able to show you what I've done :) What do you think of my a framework-agnostic argument? As the laravel-specific integrations are already built, I guess "isolating" them in a specific repository with laravel dependencies should be quite easy to do, and as you authored this project, keeping such repositories under your name seems fair, but I'm just proposing, decision is all yours :) |
I understand the dependency problem. I agree that the Laravel integration can be moved to another repository. By doing that we can skip all the We have to change some code in this repo. Can we discuss about who is going to do what (you have already did something)?! Can I leave the symfony/silex to you? You said you have already implemented something? Are you going to create a repo for that? |
Hey @ArjanSchouten, I have already replaced the few I have also already built a working Symfony integration for the Twig templating engine, and I can work on a Silex integration aswell without problem :) |
Alright. I'm working on the Laravel part. I first move the Laravel stuff out of the repository. You can make the Symfony repo if you want. Btw I started this project as a small side project. I will make things to work for now but don't know how long I support it. Depends on how it currently compares to other minifiers and their ease of use/minification ratio etc. |
@flo-sch, I just did a quick test and verified the most basic use case on Laravel 5.5. Have to do some additional work but I think that the minifier can work for you if the Laravel dependencies are deleted. I can review a PR with Laravel deps removing if you want to send one. |
Great :) I'll create a PR max. monday then! |
Hey @ArjanSchouten,
I am actually looking for a PHP standalone HTML minifer to use in several projects.
Just found out yours, which seems to be a very great job, thanks a lot for your effort!
I am personally more a Symfony developer than Laravel, and I was wondering if porting a standalone version of this minifier (I mean, framework-agnostic) would be something that could interest you?
The way I see it, the plan would be to first port a version of this project without any framework dependency, by removing the
Illuminate\Support\*
dependencies of the source code (such asStr
andCollection
+ the laravel-specific ServiceProviders and artisan Commands (+ blade placeholders etc.)Then, build some framework-specific integrations such as Laravel, Lumen, Symfony, Silex (or any other framework if anybody wants to provide a new integration), in external packages which would rely on the standalone one?
I would be ready to work on this of course (I don't think it requires a lot of time), but I prefer to kindly ask you first, if this makes sense for you, if you would be interested in extending your project in this way / helping for instance with the Laravel/Lumen integrations, or if you prefer to stay out and keep things as they are for you?
I'll wait a few days see if you're interested in any way :)
Best regards!
The text was updated successfully, but these errors were encountered: