PHP Laravel 5.7 Tymon / jwt-auth无法安装

尝试按照网站上的说明安装Tymon / jwt-auth软件包并使用它: https://jwt-auth.readthedocs.io/en/develop/laravel-installation / 似乎发布配置似乎没有做任何事情,我没有看到config / jwt.php文件,并且命令 php artisan jwt:secret </ code>不做 任何有用的东西,说没有在“jwt”命名空间中定义的命令。</ p>

有没有人有任何关于让JWT在Laravel 5.7上工作的信息?</ p>

< p>已验证它位于composer.json中:</ p>

 “require”:{
“php”:“^ 7.1.3”,
“fideloper / proxy “:”^ 4.0“,
”laravel / framework“:”5.7。*“,
”laravel / tinker“:”^ 1.0“,
”tymon / jwt-auth“:”^ 0.5.12“

},
</ code> </ pre>
</ div>

展开原文

原文

Trying to install the Tymon/jwt-auth package and work with it, following the directions on the site: https://jwt-auth.readthedocs.io/en/develop/laravel-installation/ Doesn't seem like the publish configuration seems to do anything, I'm not seeing a config/jwt.php file, and the command php artisan jwt:secretdoesn't do anything useful, saying that there are no commands defined in the "jwt" namespace.

Does anyone have any info on getting JWT working on Laravel 5.7?

Verified that it is in the composer.json:

    "require": {
    "php": "^7.1.3",
    "fideloper/proxy": "^4.0",
    "laravel/framework": "5.7.*",
    "laravel/tinker": "^1.0",
    "tymon/jwt-auth": "^0.5.12"
},

douwen5985
douwen5985 并且不要忘记检查它是否已添加到composer.json文件中。
接近 2 年之前 回复
duanjian5059
duanjian5059 你尝试过composerdump-autoload吗?如果它不起作用,关闭并重新打开终端,然后重新运行它,尝试再次安装composer..这似乎是一个作曲家的问题
接近 2 年之前 回复

2个回答



很快就可以发布这个</ p>

   “tymon / jwt-auth”:“dev-develop”
</ code> </ pre>

这适用于我的项目</ p>
</ div>

展开原文

原文

It would be nice to get this released soon you can just using this

"tymon/jwt-auth": "dev-develop"

That worked for my project



转到 composer.json </ code>。 将此添加到require:“tymon / jwt-auth”:“^ 1.0.0”</ code>。 然后运行 php composer update </ code>。 版本的jwt 0.5不受碳2.0的支持。 这对laravel 5.8来说很有用。</ p>
</ div>

展开原文

原文

Go to composer.json. Add this to require: "tymon/jwt-auth": "^1.0.0". Then run php composer update. The version of jwt 0.5 is not suported by carbon 2.0. This worked for me with laravel 5.8.

立即提问
相关内容推荐