awslabs / diagram-as-code

Diagram-as-code for AWS architecture.
Apache License 2.0
406 stars 23 forks source link

Connection lines #11

Closed pchaganti closed 3 months ago

pchaganti commented 3 months ago

Any plans to add connection lines between resources?

thanks!

ugwis commented 3 months ago

Thank you for your feedback! Yes, Currently supports a straight line between resources. The start and end points of the line specify the location as the 16-wind rose of the resource (e.g. NNW). https://github.com/awslabs/diagram-as-code/blob/main/doc/links.md

Example of Link

Diagrams:
  Resources:
    ALB: ...
    PublicSubnet1Instance: ...
    PublicSubnet2Instance: ...
  Links:
    - Source: ALB
      SourcePosition: NNW
      Target: PublicSubnet1Instance
      TargetPosition: S
    - Source: ALB
      SourcePosition: NNE
      Target: PublicSubnet2Instance
      TargetPosition: S

The documentation is not comprehensive enough, and I will work on adding more details later.

Additionally, I would like to implement features such as curves, dotted, arrows, and orthogonal lines, but I haven't implemented them yet.

pchaganti commented 3 months ago

Awesome! thank you!