(file: string, content: FileState["content"])
| 137 | } |
| 138 | |
| 139 | const setLoaded = (file: string, content: FileState["content"]) => { |
| 140 | setStore( |
| 141 | "file", |
| 142 | file, |
| 143 | produce((draft) => { |
| 144 | draft.loaded = true |
| 145 | draft.loading = false |
| 146 | draft.content = content |
| 147 | }), |
| 148 | ) |
| 149 | } |
| 150 | |
| 151 | const setLoadError = (file: string, message: string) => { |
| 152 | setStore( |