Skip to content

Commit b2ae369

Browse files
committed
fix codspeed plugin
1 parent d5dfea8 commit b2ae369

File tree

3 files changed

+41
-3
lines changed

3 files changed

+41
-3
lines changed
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
diff --git a/dist/index.cjs.js b/dist/index.cjs.js
2+
index 38ebbd413317c26c137e856edd34fee2d79951d3..d9c62124db8d09e2cd049f54c8979f3f2390ba16 100644
3+
--- a/dist/index.cjs.js
4+
+++ b/dist/index.cjs.js
5+
@@ -63,7 +63,7 @@ boolProperties.forEach(function (property) {
6+
});
7+
8+
core.tryIntrospect();
9+
-function isCodSpeedBenchOptions(options) {
10+
+function isCodSpeedBenchOptions(options = {}) {
11+
return "uri" in options;
12+
}
13+
function withCodSpeed(bench) {
14+
diff --git a/dist/index.es5.js b/dist/index.es5.js
15+
index 5353d0bc6d7ba980e29a14a3c9381a93bec83363..95d44fb46831b88f355e283a7158ff4f5719d2a1 100644
16+
--- a/dist/index.es5.js
17+
+++ b/dist/index.es5.js
18+
@@ -61,7 +61,7 @@ boolProperties.forEach(function (property) {
19+
});
20+
21+
tryIntrospect();
22+
-function isCodSpeedBenchOptions(options) {
23+
+function isCodSpeedBenchOptions(options = {}) {
24+
return "uri" in options;
25+
}
26+
function withCodSpeed(bench) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@
118118
"@babel/core": "^7.27.1",
119119
"@babel/plugin-transform-modules-commonjs": "^7.27.1",
120120
"@changesets/cli": "^2.29.4",
121-
"@codspeed/tinybench-plugin": "^4.0.1",
121+
"@codspeed/tinybench-plugin": "patch:@codspeed/tinybench-plugin@npm%3A4.0.1#~/.yarn/patches/@codspeed-tinybench-plugin-npm-4.0.1-a79378f455.patch",
122122
"@formatjs/intl-segmenter": "11.7.10",
123123
"@mitata/counters": "^0.0.8",
124124
"@react-native/metro-babel-transformer": "^0.79.2",

yarn.lock

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1287,7 +1287,7 @@ __metadata:
12871287
languageName: node
12881288
linkType: hard
12891289

1290-
"@codspeed/tinybench-plugin@npm:^4.0.1":
1290+
"@codspeed/tinybench-plugin@npm:4.0.1":
12911291
version: 4.0.1
12921292
resolution: "@codspeed/tinybench-plugin@npm:4.0.1"
12931293
dependencies:
@@ -1299,6 +1299,18 @@ __metadata:
12991299
languageName: node
13001300
linkType: hard
13011301

1302+
"@codspeed/tinybench-plugin@patch:@codspeed/tinybench-plugin@npm%3A4.0.1#~/.yarn/patches/@codspeed-tinybench-plugin-npm-4.0.1-a79378f455.patch":
1303+
version: 4.0.1
1304+
resolution: "@codspeed/tinybench-plugin@patch:@codspeed/tinybench-plugin@npm%3A4.0.1#~/.yarn/patches/@codspeed-tinybench-plugin-npm-4.0.1-a79378f455.patch::version=4.0.1&hash=b0395e"
1305+
dependencies:
1306+
"@codspeed/core": "npm:^4.0.1"
1307+
stack-trace: "npm:1.0.0-pre2"
1308+
peerDependencies:
1309+
tinybench: ^2.3.0
1310+
checksum: 10c0/842a90bf9a0a8576b47d84c80a5dd31eeef955ccf200988f7a92725a70f1e9c7e8f9aa3653254bfa47a5a90a0b10b14cdbd85d1ac6dbe17d551ed45fe82c8084
1311+
languageName: node
1312+
linkType: hard
1313+
13021314
"@esbuild/aix-ppc64@npm:0.25.0":
13031315
version: 0.25.0
13041316
resolution: "@esbuild/aix-ppc64@npm:0.25.0"
@@ -5581,7 +5593,7 @@ __metadata:
55815593
"@babel/core": "npm:^7.27.1"
55825594
"@babel/plugin-transform-modules-commonjs": "npm:^7.27.1"
55835595
"@changesets/cli": "npm:^2.29.4"
5584-
"@codspeed/tinybench-plugin": "npm:^4.0.1"
5596+
"@codspeed/tinybench-plugin": "patch:@codspeed/tinybench-plugin@npm%3A4.0.1#~/.yarn/patches/@codspeed-tinybench-plugin-npm-4.0.1-a79378f455.patch"
55855597
"@formatjs/intl-segmenter": "npm:11.7.10"
55865598
"@mitata/counters": "npm:^0.0.8"
55875599
"@react-native/metro-babel-transformer": "npm:^0.79.2"

0 commit comments

Comments
 (0)