Skip to content
This repository has been archived by the owner on Feb 18, 2023. It is now read-only.

[Question] How do you generate blueprint api documentation? #39

Closed
sctteea opened this issue Jul 13, 2018 · 2 comments
Closed

[Question] How do you generate blueprint api documentation? #39

sctteea opened this issue Jul 13, 2018 · 2 comments
Labels

Comments

@sctteea
Copy link

sctteea commented Jul 13, 2018

I tried using:

php artisan api:docs --name Docs

but it only exports 3 lines:

FORMAT: 1A

# Docs

How are the .apib view files being generated?

@kslimani
Copy link
Contributor

Take a look at this project.

Just do a npm install -D aglio (or install globally), then just add an npm tasks in your package.json file

{
    "scripts": {
        "apidoc-dist": "aglio -i path/to/index.apib -o path/to/file.html",
        "apidoc-watch": "aglio -s -h 0.0.0.0 -p 3000 -i path/to/index.apib"
    },
 }

@joselfonseca
Copy link
Owner

@sctteea Thanks for the question, the API blueprint file is written manually, we are not using annotations to generate it. We found out that that does not generate the docs how we want them. We do use aglio to generate the HTML out. You can add the annotations to the controllers and generate the apib file that way if you want.

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

No branches or pull requests

3 participants