Dispatch pageLoaded event upon plug updates
This commit is contained in:
parent
c27cd81271
commit
0e58f95920
@ -208,6 +208,7 @@ export class HttpServer {
|
|||||||
switch (body.operation) {
|
switch (body.operation) {
|
||||||
case "fetch": {
|
case "fetch": {
|
||||||
const result = await performLocalFetch(body.url, body.options);
|
const result = await performLocalFetch(body.url, body.options);
|
||||||
|
console.log("Proxying fetch request to", body.url);
|
||||||
response.headers.set("Content-Type", "application/json");
|
response.headers.set("Content-Type", "application/json");
|
||||||
response.body = JSON.stringify(result);
|
response.body = JSON.stringify(result);
|
||||||
return;
|
return;
|
||||||
|
@ -469,6 +469,7 @@ export class Editor {
|
|||||||
if (this.plugsUpdated) {
|
if (this.plugsUpdated) {
|
||||||
// To register new commands, update editor state based on new plugs
|
// To register new commands, update editor state based on new plugs
|
||||||
this.rebuildEditorState();
|
this.rebuildEditorState();
|
||||||
|
this.dispatchAppEvent("editor:pageLoaded", this.currentPage);
|
||||||
if (operations) {
|
if (operations) {
|
||||||
// Likely initial sync so let's show visually that we're synced now
|
// Likely initial sync so let's show visually that we're synced now
|
||||||
this.flashNotification(`Synced ${operations} files`, "info");
|
this.flashNotification(`Synced ${operations} files`, "info");
|
||||||
|
Loading…
Reference in New Issue
Block a user