[英]Class path.config does not exist - Lumen 5.2
i have a little problem while adding GoogleMaps Package By alexpechkarev link : https://alexpechkarev.github.io/google-maps/ to lumen framework version 5.2 I added the ServiceProvider and Facade to my app.php : 我在添加GoogleMaps包时遇到一些问题通过alexpechkarev链接: https ://alexpechkarev.github.io/google-maps/到流明框架版本5.2我将ServiceProvider和Facade添加到我的app.php:
$app->register(GoogleMaps\ServiceProvider\GoogleMapsServiceProvider::class);
class_alias(GoogleMaps\Facade\GoogleMapsFacade::class, 'GoogleMaps');
but when, I go to my command line and tape : php artisan I get this error message : 但是什么时候,我去我的命令行和磁带:php artisan我收到此错误消息:
[ReflectionException] Class path.config does not exist
[ReflectionException]类path.config不存在
It is trying to resolve path.config
from the IoC container, but it hasn't been defined. 它正在尝试从IoC容器中解析
path.config
,但尚未定义。
Somewhere before you register your GoogleMapsServiceProvider
, you need to add that value to your container. 在注册
GoogleMapsServiceProvider
之前的某个地方,您需要将该值添加到容器中。
$app->instance('path.config', app()->basePath() . DIRECTORY_SEPARATOR . 'config');
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.