Skip to content

feat(config): dynamic hot reloading#1345

Draft
JakeStanger wants to merge 1 commit intomasterfrom
feat/hot-reload
Draft

feat(config): dynamic hot reloading#1345
JakeStanger wants to merge 1 commit intomasterfrom
feat/hot-reload

Conversation

@JakeStanger
Copy link
Owner

@JakeStanger JakeStanger commented Jan 25, 2026

At long last, config hot reloading! This introduces a config diffing system that tries to minimise the amount of reloading that needs to take place, according to the following rules:

  • Monitors switching from single <--> multiple bars will perform a full reload of all bars.
  • Bars with non-module configuration changes (ie changing position etc), or a change to the number of modules are fully reloaded.
  • Changes at a module level replace just that module.

This means that you can add, remove and change entire monitor configurations, individual bars, and modules and Ironbar will do its best to minimise the impact.

Hot-reloading does not currently support top-level config options other than bar and monitors. Some of these are likely to never be supported but this still requires exploration.

This also adds a new top-level hot_reload option, which takes two formats:

  • hot_reload: <true/false> - enables/disables for both config and styles.
  • hot_reload.config and hot_reload.style which can be used to toggle each system separately.

The code for this is still a little messy and prototypal, and I'm not sure I've caught every edge case yet, so leaving as draft for now. This does work for the most part though, so publishing for others to test and play with.

@JakeStanger JakeStanger force-pushed the feat/hot-reload branch 2 times, most recently from b3a2020 to 25d388c Compare January 25, 2026 16:26
@JakeStanger JakeStanger force-pushed the feat/hot-reload branch 3 times, most recently from f628123 to 32b1c0f Compare February 13, 2026 21:32
At long last, config hot reloading! This introduces a config diffing system that tries to minimise the amount of reloading that needs to take place, according to the following rules:

- Monitors switching from single <--> multiple bars will need a full reload of all bars
- Bars with non-module configuration changes, or a change to the number of modules are fully reloaded
- Changes at a module level replace just that module.

This means that you can add, remove and change entire monitor configurations, individual bars, and modules and Ironbar will do its best to minimise the impact.

Hot-reloading does not currently support top-level config options other than `bar` and `monitors`. Some of these are likely to never be supported but this still requires exploration.

This also adds a new top-level `hot_reload` option, which takes two formats:

- `hot_reload: <true/false>` - enables/disables for both config and styles.
- `hot_reload.config` and `hot_reload.style` which can be used to toggle each system separately.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant