Skip to content

Commit 13e3926

Browse files
Nest workflow sections under choosing a workflow heading (#525)
Generated-By: mintlify-agent Co-authored-by: mintlify[bot] <109931778+mintlify[bot]@users.noreply.github.com>
1 parent 4c23ead commit 13e3926

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

guides/developer/dashboards-as-code.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ There are two main approaches to working with dashboards as code. You can mix an
1616
| **Setup complexity** | Minimal — just the CLI | Requires CI/CD and space permissions |
1717
| **Best for** | Quick edits, AI-assisted changes, ad-hoc updates | Regulated environments, multi-instance deployments, teams that want strict change control |
1818

19-
## Disposable editing (recommended)
19+
### Disposable editing (recommended)
2020

2121
When using dashboards as code with AI agents or CLI tools, we recommend treating the downloaded files as **temporary working files** rather than a permanent source of truth. This is the best starting point for most teams.
2222

23-
### The disposable workflow
23+
#### The disposable workflow
2424

2525
1. **Download** the content you want to edit using `lightdash download`
2626
2. **Make your changes** locally (manually or with AI assistance)
@@ -29,27 +29,27 @@ When using dashboards as code with AI agents or CLI tools, we recommend treating
2929

3030
This approach keeps the Lightdash application as your source of truth while still enabling powerful code-based editing workflows.
3131

32-
### Why disposable?
32+
#### Why disposable?
3333

3434
Treating dashboards as code as disposable config files provides flexibility:
3535

3636
- **UI changes remain easy** — team members can continue making updates directly in the Lightdash UI without needing to sync a codebase
3737
- **No repository maintenance** — you avoid the overhead of keeping code files synchronized with UI changes
3838
- **Best of both worlds** — you get the power of code-based editing and AI assistance without the rigidity of a code-first workflow
3939

40-
## Git-managed dashboards
40+
### Git-managed dashboards
4141

4242
An alternative approach where your **Git repository is the single source of truth** for charts and dashboards. All changes flow through version control, and the UI is read-only for managed content.
4343

44-
### When to use this workflow
44+
#### When to use this workflow
4545

4646
- You want a full audit trail of every dashboard change via Git history
4747
- You want to enforce review processes (pull requests, approvals) before changes reach production
4848
- You're comfortable with all edits happening in code rather than the UI
4949
- You want to validate dashboard changes in [preview environments](/guides/developer/preview-projects) before merging
5050
- You're deploying the same content across multiple Lightdash instances
5151

52-
### Lock down the UI
52+
#### Lock down the UI
5353

5454
For this workflow to succeed, you need to prevent ad-hoc UI edits from drifting out of sync with your repository. Use **space permissions** to enforce this:
5555

@@ -58,7 +58,7 @@ For this workflow to succeed, you need to prevent ad-hoc UI edits from drifting
5858

5959
You don't have to manage everything this way. Organize code-managed content into specific spaces with restricted permissions, and leave other spaces open for UI editing.
6060

61-
### Making changes
61+
#### Making changes
6262

6363
The typical workflow for editing Git-managed dashboards:
6464

@@ -69,7 +69,7 @@ The typical workflow for editing Git-managed dashboards:
6969
5. **Open a pull request** — once the changes look good in the preview, commit and open a PR for review
7070
6. **Merge and deploy** — on merge to your main branch, a CI job runs `lightdash deploy` and `lightdash upload --force` to push changes to production
7171

72-
### CI/CD setup
72+
#### CI/CD setup
7373

7474
To fully automate this workflow, set up two CI jobs:
7575

0 commit comments

Comments
 (0)