You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-`usePluginSettings`, `useHostData`, `useSlotContext`: read plugin and host state inside your React components.
49
50
-`useAppTheme`: read HaloForge theme mode and CSS variables inside your plugin.
50
51
-`enterpriseGateway`: call the host-managed image gateway without exposing cloud tokens. The function name is retained for compatibility; user-facing UI should say "HaloForge Cloud gateway" or "Managed gateway".
@@ -62,6 +63,7 @@ Prefer these host helpers over reading `window.__HF_HOST` directly:
62
63
-`pluginWindows()` / `usePluginWindows()` for host-managed route/resource window opening
63
64
-`pluginCurrentWindow()` / `usePluginWindowTitle()` for the current native window title
64
65
-`pickHostFile()` / `pickHostDirectory()` / `saveHostFile()` for host-owned file dialogs
66
+
-`watchHostFile()` / `useHostFileWatch()` for host-managed file change notifications
65
67
-`useHostModels()` / `useAvailableModels()` for model lists and current selection
66
68
-`useHostAI()` for AI transport, session creation, stream-state polling, and generation stop
67
69
-`enterpriseGateway()` for host-managed image generation and image edits
@@ -71,6 +73,36 @@ Prefer these host helpers over reading `window.__HF_HOST` directly:
71
73
72
74
These helpers currently adapt to HaloForge's existing host bridge internally, but they give plugin authors one documented surface that can keep working as HaloForge evolves.
73
75
76
+
## File Watching
77
+
78
+
Declare the public capability and permission:
79
+
80
+
```json
81
+
{
82
+
"host_capabilities": ["file_watch"],
83
+
"permissions": [
84
+
{ "type": "host_file_watch" }
85
+
]
86
+
}
87
+
```
88
+
89
+
React plugins can follow a file without polling or using host internals:
0 commit comments