js-proto-docs
2023-9-16 00:18:46 Author: github.com(查看原文) 阅读量:16 收藏

Autogenerated Javascript documention of all modules/functions etc available in Nuclei Javascript Protocol

Generate/Update HTML Docs

Install clean-jsdoc-theme

refer docs for more details or install using below command

$ npm install -g clean-jsdoc-theme

Install jsdoc

refer docs for more details or install using below command

Locate clean-jsdoc-theme directory

Its usually located at $(npm root -g)/clean-jsdoc-theme when installed globally

Clone target nuclei repo and navigate to desired branch

$ gh repo clone projectdiscovery/nuclei

Generate docs

$ jsdoc -R nuclei/docs/template-guide/javascript.mdx -r -d docs/ -t $(npm root -g)/clean-jsdoc-theme nuclei/v2/pkg/js/generated/js

If above command fails, try updating paths Here's expected command

jsdoc -R [Homepage.md] -r -d api_reference -t [optional: jsdoc theme to use] generated/js

Verify generated docs

$ cd docs && simplehttpserver

Contributing

If you want to update / fix something in docs etc . Please update docs present at https://github.com/projectdiscovery/nuclei/tree/main/v2/pkg/js/generated/js and then follow above steps to generate docs and create a PR with updated docs.


文章来源: https://github.com/projectdiscovery/js-proto-docs
如有侵权请联系:admin#unsafe.sh