dyonis/yii2-swagger

OA3 swagger module for Yii2

1.0 2022-08-06 09:38 UTC

This package is auto-updated.

Last update: 2024-11-06 14:38:47 UTC


README

OA3 Swagger module for Yii2


version Download Issues

Integration swagger-ui with Yii2.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist dyonis/yii2-swagger "~1.0" --dev

or add

"dyonis/yii2-swagger": "~1.0"

to the require section of your composer.json file.

Usage

Add to your application config:

'modules'=>[
    ...
   'swagger'=> [
       'class' => \dyonis\yii2\swagger\Module::class,
       'apiDoc' => '@app/modules/api/v1/doc/swagger.yml',
       'cacheDuration' => 1,
   ],
],

License

MIT