Yii Framework Forum

Any ETA for first Public (Pre-alpha or something) for Testing


#21

I’ve never really felt Blade was lacking in anything or that it wasn’t powerful enough. And if I don’t want to use it I don’t have to - it’s not a limitation as I can easily use something different like Phug. The point is, it’s there and readily available IF I want to use it.


(Breg) #22

GSTAR, there are two different strategies for software developement behind this question:

  1. The constructivist approach seeks to create or identify the minimal building blocks that can be combined to provide the final solution. Unix and Linux themselve follow this approach.
  2. The product-ist approach seeks to develop one product further, adding features and market awareness with every step. Typical examples are Windows and SAP.
    For an invenstor (be it with capital or skill) the productist path seems to be more promising (while numerous failures are naturally forgotten or subdued).

From a developer perspective, the constructivist path prooves to be more flexible, more fun and saver. And for the client, in the end, more powerful.
As a 20-year long consultant with SAP, I had several situations when clients were desperate and couldn’t believe that the product that ticked the most feature boxes can not be adapted to their ‘simple request’. This is because this approach produces bloated products and solutions sonner or later, while pushing aside simple basics of mathematics, like Occam’s razor.
For example, from your list of ‘superior’ Laravel features, I would delegate half to the database layer. The database developer knows triggers, stored procedures etc. and any solution there will be simpler, more self-documenting, platform-independent and vastly faster to execute instead of replicating it on the framework-level.

You don’t have a database developer?
Ok, but that’s not a feature :wink:


(Alexander Makarov) #23

We do monitor other frameworks. I’m working daily with Symfony 2-4, Yii 1.1 in my fulltime job. I’m a teamlead in quite large company. Checking Laravel from time to time. While Symfony, Laravel, Yii are fine frameworks, there’s no silver bullet. For example, Laravel is super-major in US/UK, has some cool features and definitely best marketing, Symfony is well-suited for big companies where you barely control developers and the more restrictions the better, Yii has best i18n layer, great performance w/o caching, well-made generator, best AR implementation etc. When I’m asked “which framework to choose” I say none. Learn all of them and choose based on the project needs and your preferences.


(Jacob Moen) #24

I really like that the frameworks are different. :slight_smile:
There are more than enough unnamed frameworks trying to be everything for everyone, Jack of all trades…
But those big four have each their own identity. So, like Samdark, I don’t see them as competitors as such, but more like alternatives.
As a chef, I do not use a Swiss army knife, but I do use different knives depending on the job : santoku, chef, pairing…


(Serban Cristian) #25

Isn’t this non-sense actually ?

I mean yes, i can understand to pick the right language for the project, but a framework…? do you think people have the time to learn 5 top frameworks? I personally don’t think so, and even if people would do that, they can’t be pro-efficient in all of them and they will always tend to use the one they know better.

The framework must provide the building blocks and if it fails to do so, people simple disregard it and move to something else, but this is before they invest years in using it, at that point people don’t really switch that easy.

I think Yii is on the right track overall with the 3.0, it’s just you are moving way too slow and this will cost in the long run.


(Serban Cristian) #26

That’s understandable, but why is it taking so long? I mean, i proposed this years ago and nothing was made in this direction.


(Alexander Makarov) #27

It’s not nonsense. Personally I’m fine with lots of PHP frameworks including CodeIgniter, CakePHP, ZF1, ZF2, Symfony 2,3,4, Yii 1.1, Yii 2.0.


(Alexander Makarov) #28

Because it’s not easy and because we’re busy with other things as well. Also it’s not true that nothing was made. @cebe actually researched the topic well so we know how to do it now.


(Fsb) #29

Laravel already exists and does a pretty decent job of being Laravel. I don’t think it adds to the overall market of ideas if Yii tries to be Laravel too.


(Alexander Makarov) #30

He-he. Yeah. Makes no sense to be Laravel copy. We can do better… at least in some aspects.


#31

This is precisely my point. Laravel is setting the standards, so Yii has a lot of ground to make up. If you can do it better then great, if not then developers will inevitably question whether Yii is the right choice.


(Jacob Moen) #32

Now you are making up things to support your case.
He never said that Laravel is setting the standard. :smile:

In the world outside of North America, Laravel is not setting the standard.

If you really mean that Laravel is the standard upon which Yii must measure, then - for the love of God: use Laravel!
That’s better, instead of being miserable. :wink:


(Fsb) #33

This is precisely my point. Laravel is setting the standards, so Yii has a lot of ground to make up. If you can do it better then great, if not then developers will inevitably question whether Yii is the right choice.

That’s almost exactly the opposite of my point.

Laravel is one thing and Yii is a different thing—not the same kind of thing as Laravel but incomplete or not as good. They are different vectors within a vast design space—not different scalars in one dimensional space. Apple and oranges—not two different apples where one is bigger and better than the other.

If Laravel were the standard that Yii and everyone else should try to meet then Yii would add nothing to the state of the art and should not exist. Yii devs should instead make contributions to Laravel or find something else to do. It’s just a waste to have two projects doing the same thing with one of them always trying to catch the other.

Collectively we move the state of the art forwards by trying different ideas, learning from everyone’s wins and losses as we go. To see one project (e.g. Laravel) as setting the standards limits this exploration and limits the way we think about problems and possible technologies.

That’s my point about “the overall market of ideas.” Yii is exploring different areas of design space and that’s a good thing.


(Alexander Makarov) #34

Great points, @thefsb. An example of different exploration field is i18n. It’s not important for North America but is extremely important for Europe and Asia.


(Stefano Mtangoo) #35

… and Africa of course :slight_smile:


#36

I think you guys got the wrong end of the stick. I’m not saying Yii must become a copy of Laravel. What I’m saying is, I have used Laravel on a few different projects, so I’ve had the opportunity to properly compare the two. I’ve found Laravel does some things a lot better than Yii, but not the same can be said about Yii.

Of course Yii needs to explore different areas of design, but inevitably developers will compare features with other frameworks and decide which framework does it better. A quick example is migrations. So much easier to do in Laravel - so why not look at how they’ve done it and try to do it better, or at least similar?

Same for environment configuration. I know Yii 3 is going in the direction of dotenv - which is a good move, but Laravel have been doing that for years.

Again like I said before I want to help improve Yii. I’m just giving you my feedback based on what I have seen for myself. This is not a case of “Laravel is better than Yii” - you can never say that. But you can look at individual features and say “yes that is a more elegant way of doing it”.


#37

Another quick example. Sometimes when I want to quickly debug something in Laravel, I can just use the dd() function anywhere. So nice and simple and easy to remember. In Yii the equivalent is to do the following:

\yii\helpers\VarDumper::dump($var);

Difficult to remember and a lot more typing. Now I know you will probably say "you can create your own wrapper dd() function for VarDumper()". But why can’t there be a standard helper function for this?

Every Laravel developer knows the dd() function. I can jump on to any Laravel project and use that function without having to go documentation, etc. If we all created our own wrapper function for VarDumper() we’d all have our own independent one. There would be no consistency.

Here is an issue from over 2 years ago where this is discussed in length: https://github.com/yiisoft/yii2/issues/7352

I really don’t understand why this was rejected by the dev team.


(Alexander Makarov) #38

We did that in the past many times checking ASP.NET, RoR, Spring, Symfony, Laravel etc. You’re very welcome to propose individual enhancements/features and take inspiration from other projects but it’s not very productive to say that other product is doing X better without proposing any steps to improve Yii.

Blind-copying features isn’t good. So far I have seen features in other framework done differently where some or even most parts were made well or better. But in all these cases there was something in these features that Yii does better. That’s why I think it’s good to have a productive discussion on each feature taking best parts and doing the rest better.


(Alexander Makarov) #39

About dd() specifically, it’s a bad practice to do “spartan-debug” with echo instead of properly configuring XDebug. Personally I don’t think it’s a good thing to encourage bad practices making them easy to perform (yeah, I know we actually did that in some cases). That’s why dd() isn’t there yet. But, if you want this feature bad, create an issue at github in https://github.com/yiisoft/yii-core, start a voting and discussion and if there are many developers who want that and no serious objections, it will end up in Yii.

In the issue you’ve linked to feedback was rather controversial.


(Alexander Makarov) #40

Anyway, we’re going off-topic. Let’s discuss separate ideas in separate topics.