@startuml
!include https://raw.githubusercontent.com/adrianvlupu/C4-PlantUML/latest/C4_Component.puml
!define DEV2 https://raw.githubusercontent.com/tupadr3/plantuml-icon-font-sprites/master/dev2
!include DEV2/nodejs.puml
!include DEV2/html5.puml
!include DEV2/javascript.puml
!include DEV2/github.puml


LAYOUT_WITH_LEGEND()

title [Component Diagram] App container

Container(lib, "Library", "Node.js", "Reads/writes configuration and updates markdown text", "nodejs") [[../Lib/container.svg]]

System_Ext(gh, "GitHub", "Code Hosting and VCS", "github")
Container_Ext(probot, "Probot", "Node.js", "GitHub Apps to automate and improve your workflow", "nodejs")
Container_Ext(compromise, "Compromise", "Node.js", "NLP package", "nodejs")

Container_Boundary(app, "App") {
  Component(api, "API", "Node.js", "Source code and GH Webhooks", "nodejs")
  Component(applib, "Lib", "Node.js", "Library code for the bot", "nodejs")

  Rel_Neighbor(api, applib, "uses", "CJS import")
}

Rel_D(api, gh, "listens to", "webhooks")
Rel_R(applib, lib, "uses", "CJS import")
Rel(applib, probot, "uses", "CJS import")
Rel(applib, compromise, "uses", "CJS import")

@enduml