I’m starting a new project using Yii 2 (since Yii 3 is not yet finished when it comes to ActiveRecord etc), and was wondering if it’s possible to inject dependencies in the controller classes instead of calling the global Yii::$app variable? E.g. for Yii::$app->user.
Or maybe it’s better to use Yii 3 and then pull other ORM packages as an alternative to those yet not finished?
If you insist with Yii2 @terabytesoftw have written excellent tutorial on that. I hope he puts it in something accessible like a forum post or a blog post.