So I follow the guide here:
http://www.yiiframework.com/doc-2.0/guide-tutorial-yii-integration.html#using-both-yii2-yii1
for somereason all Yii::import() inside class are not working.
for example I have a widget that extend CPortlet like this
Yii::import('zii.widgets.CPortlet');
class sideWidget extends CPortlet{
}
it will generate error "include(CPortlet.php): failed to open stream: No such file or directory"
I was able to workaround it by included zii.widget.* inside config/main.php import
but then some class like CJavaScript::quote will generate another error because it use
Yii::import(‘system.vendors.zend-escaper.Escaper’);
this is also resolvable by putting ‘system.vendors.zend-escaper.*’ in the config/main.php import
but then it would require me to put all the import be it inside the framework or my own project into config.
Did I miss something here?