After checking out the Github Actions Hackathon, I started exploring more about GitHub actions and was amazed by learning the amount of power they possess.
In this post, I would like to share the idea on which I am working for this hackathon (This is not a submission)
The Idea
Current Progress
Right now, the action scans the backend javascript file for express API Calls and just console logs them on each push to the repository
Description
I plan to scan the backend server file for API calls and also scan the router routes for categorized API calls and then use the keywords get, post, etc to fetch the API call type.
The backend file path, app variable name used can be given a custom input.
prafulla-codes / express-autodocs
A GitHub action which automatically generates documentation for your express APIs.
π‘ Introduction
This action automatically scans for express APIs in your codebase and generates a documentation website
Whats New?
- Added JSDOC Like Syntax to define APIs (Thanks to @rahil1304)
- Refactored Code & Reduced Bugs (Thanks to @rosborne132 & @KulkarniSuraj)
- Added Unit Tests
How to add to your workflow β
To add this action to your workflow simply modify your workflows main.yml file.
# This is a basic workflow to help you get started with Express AutoDocs Action
name: Express AutoDocs.
# This specifies when the action should occur
on:
push:
branches: [master]
jobs:
generate_docs_job:
runs-on: ubuntu-latest
name: Generating Docs
steps:
# this step checks out the master branch of your repo using checkout action.
- name: Checks out the repository
id: checksout-repository
uses: actions/checkout@v2
with:
repository: ''
# this step generates the docs
β¦
Top comments (2)
Amazing!
Thank you π€π