Defaults
The DSL is designed to be as compact as possible. When used in conjunction with Structurizr Lite or the Structurizr CLI, the following DSL fragment will automatically:
- Create the implied relationship between the
user
andsoftwareSystem
elements. - Create a default set of views (1 x System Landscape, 1 x System Context, 1 x Container - all with auto-layout enabled, see ViewSet.createDefaultViews()).
- Add some default element styles from a theme.
workspace {
model {
user = person "User"
softwareSystem = softwareSystem "Software System" {
webapp = container "Web Application"
database = container "Database"
}
user -> webapp "Uses"
webapp -> database "Reads from and writes to"
}
views {
theme default
}
}