added format command and added trailing commas to reduce conflicts

This commit is contained in:
dswbx
2025-02-26 20:06:03 +01:00
parent 88b5359f1c
commit 7743f71a11
414 changed files with 3622 additions and 3610 deletions

View File

@@ -31,13 +31,13 @@ export async function getCached(config: CloudflareBkndConfig, { env, ctx, ...arg
async ({ params: { app } }) => {
saveConfig(app.toJSON(true));
},
"sync"
"sync",
);
await config.beforeBuild?.(app);
},
adminOptions: { html: config.html }
adminOptions: { html: config.html },
},
{ env, ctx, ...args }
{ env, ctx, ...args },
);
if (!cachedConfig) {

View File

@@ -23,7 +23,7 @@ export async function getDurable(config: CloudflareBkndConfig, ctx: Context) {
config: create_config,
html: config.html,
keepAliveSeconds: config.keepAliveSeconds,
setAdminHtml: config.setAdminHtml
setAdminHtml: config.setAdminHtml,
});
const headers = new Headers(res.headers);
@@ -32,7 +32,7 @@ export async function getDurable(config: CloudflareBkndConfig, ctx: Context) {
return new Response(res.body, {
status: res.status,
statusText: res.statusText,
headers
headers,
});
}
@@ -48,7 +48,7 @@ export class DurableBkndApp extends DurableObject {
html?: string;
keepAliveSeconds?: number;
setAdminHtml?: boolean;
}
},
) {
let buildtime = 0;
if (!this.app) {
@@ -73,7 +73,7 @@ export class DurableBkndApp extends DurableObject {
return c.json({
id: this.id,
keepAliveSeconds: options?.keepAliveSeconds ?? 0,
colo: context.colo
colo: context.colo,
});
});
@@ -82,7 +82,7 @@ export class DurableBkndApp extends DurableObject {
adminOptions: { html: options.html },
beforeBuild: async (app) => {
await this.beforeBuild(app);
}
},
});
buildtime = performance.now() - start;
@@ -101,7 +101,7 @@ export class DurableBkndApp extends DurableObject {
return new Response(res.body, {
status: res.status,
statusText: res.statusText,
headers
headers,
});
}

View File

@@ -6,9 +6,9 @@ export async function makeApp(config: CloudflareBkndConfig, ctx: Context) {
return await createRuntimeApp(
{
...makeCfConfig(config, ctx),
adminOptions: config.html ? { html: config.html } : undefined
adminOptions: config.html ? { html: config.html } : undefined,
},
ctx
ctx,
);
}