Skip to content
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

error after installing simplechat and twig in yii2 #33

Open
madeeloc opened this issue Apr 13, 2020 · 2 comments
Open

error after installing simplechat and twig in yii2 #33

madeeloc opened this issue Apr 13, 2020 · 2 comments

Comments

@madeeloc
Copy link

Twig\Error\RuntimeError
An exception has been thrown during the rendering of a template ("Failed to instantiate component or class "yii\bootstrap\BootstrapAsset".").

Caused by: Invalid Configuration – yii\base\InvalidConfigException
Failed to instantiate component or class "yii\bootstrap\BootstrapAsset".
in /var/www/html/hrhotlist/vendor/yiisoft/yii2/di/Container.php at line 449


Caused by: ReflectionException
Class yii\bootstrap\BootstrapAsset does not exist
in /var/www/html/hrhotlist/vendor/yiisoft/yii2/di/Container.php at line 447

Can someone tell me about this error
I am installing the module simple chat and also installed the twig in yii2 app
but when i hit url basepath/message then above error show

Please help out of this error

@warednsour
Copy link

i think the problem is in the config\web.php
please make sure in the very first paramets that you have pasted this
$config = [ 'id' => 'basic', 'basePath' => dirname(__DIR__), 'bootstrap' => ['simplechat'], 'aliases' => [ '@bower' => '@vendor/bower-asset', '@npm' => '@vendor/npm-asset', ], 'components' => [ 'request' => [

@madeeloc
Copy link
Author

hello @warednsour ,

After doing that one now i found the below error

Twig\Error\RuntimeError
An exception has been thrown during the rendering of a template ("call_user_func_array() expects parameter 1 to be a valid callback, class 'NavBar' not found").

Caused by: yii\base\ErrorException
call_user_func_array() expects parameter 1 to be a valid callback, class 'NavBar' not found
in /var/www/html/hrhotlist/vendor/yiisoft/yii2-twig/src/Extension.php at line 228

Can you please help me out this too?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants