Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
liamgriffiths committed Jul 22, 2024
1 parent 22f793e commit c8d7e8b
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
13 changes: 8 additions & 5 deletions examples/jinja.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,14 @@ async function main() {
const a = new Box({ value: ["a", "b"] });
const b = new Box({ value: { x: "x" } });

const f = sb.jinja('as=[{% for a in as %}{{a}},{% endfor%}], b={{b["x"]}}, c={{c}}', {
as: a.future.value,
b: b.future.value,
c: "1234",
});
const f = sb.jinja(
'as=[{% for a in as %}{{a}},{% endfor%}], b={{b["x"]}}, c={{c}}',
{
as: a.future.value,
b: b.future.value,
c: "1234",
},
);

const c = new Box({ value: f });

Expand Down
2 changes: 1 addition & 1 deletion src/Future.ts
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ export class Jinja extends Directive {
}
};
collectFutures([template, variables]);
this.items = Array.from(futures)
this.items = Array.from(futures);
}

override next(..._items: any[]) {
Expand Down
7 changes: 6 additions & 1 deletion src/Node.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
import { idGenerator } from "substrate/idGenerator";
import { Future, FutureAnyObject, Trace, replaceWithPlaceholders } from "substrate/Future";
import {
Future,
FutureAnyObject,
Trace,
replaceWithPlaceholders,
} from "substrate/Future";
import { SubstrateResponse } from "substrate/SubstrateResponse";
import { NodeError, SubstrateError } from "substrate/Error";
import { AnyNode } from "substrate/Nodes";
Expand Down
2 changes: 1 addition & 1 deletion src/Platform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export const getPlatformProperties = (): PlatformProperties => {
runtimeVersion:
typeof Deno.version === "string"
? Deno.version
: (Deno.version?.deno ?? "unknown"),
: Deno.version?.deno ?? "unknown",
};
}
if (typeof EdgeRuntime !== "undefined") {
Expand Down

0 comments on commit c8d7e8b

Please sign in to comment.