documentationcompodoc

Need to change port for document opening in Compodoc


I am using Compo-doc for documenting my Angular 2 application. After successful creation of documentation folder in directory structure of my application, when I am trying to access the Document on browser through the command, by default it opens on "localhost:8080" port. We are already using 8080 port for Micro-services. So I need to change the port for documentation Rendering. Can any one help me to solve this issue?


Solution

  • Looking at the Compodoc website, under the usage section (https://compodoc.github.io/website/guides/usage.html) you will find different commands to customise your application, generally using the command:

    compodoc <src> [options]

    and in your case "Change default serving port", it should have as value for src and option respectively:

    -r, --port [port]
    

    I hope it helps!