Skip to content

Commit 8de8bd6

Browse files
committed
chore: fix typescheck issue
1 parent 8802b6c commit 8de8bd6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/bench/bench.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ import { readFile } from "node:fs/promises";
22
import { fileURLToPath } from "node:url";
33
import { group, baseline, bench, run } from "mitata";
44
import * as capnpES from "capnp-es";
5-
import * as capnpTS from "capnp-ts";
6-
import protobuf from "protobufjs";
75

86
// JSON
97
const decoder = new TextDecoder();
@@ -42,6 +40,7 @@ const capnpESBench = {
4240
};
4341

4442
// capnp-ts
43+
const capnpTS = await import("capnp-ts" as any);
4544
const { AddressBook: capnpTSStruct } = await import(
4645
"./data/capnp/schema-legacy.cjs" as any
4746
);
@@ -60,6 +59,7 @@ const capnpTSBench = {
6059
};
6160

6261
// protobuf
62+
const protobuf = await import("protobufjs").then((r) => r.default || r);
6363
const protobufType = await protobuf
6464
.load(fileURLToPath(new URL("data/protobuf/schema.proto", import.meta.url)))
6565
.then((pb) => pb.lookupType("pi0.test.AddressBook"));

0 commit comments

Comments
 (0)