dqc19941228
2018-12-23 02:08
浏览 169
已采纳

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

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"
},

图片转代码服务由CSDN问答提供 功能建议

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

有没有人有任何关于让JWT在Laravel 5.7上工作的信息? < p>已验证它位于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“  
},
   
 
  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • dovs36921 2018-12-23 04:34
    已采纳

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

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

    That worked for my project

    点赞 打赏 评论
  • douwenpin0428 2019-05-25 11:00

    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.

    点赞 打赏 评论

相关推荐 更多相似问题