Skip to content

Commit 032538d

Browse files
authored
arkregex 0.0.1 (#1526)
1 parent 6b97753 commit 032538d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+515
-217
lines changed

.github/workflows/pr.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,8 @@ jobs:
3434
include:
3535
- os: ubuntu-latest
3636
node: lts/-1
37-
# reenable once localStorage issue is addressed in node 25:
38-
# https://github.com/nodejs/node/issues/60303
39-
# - os: ubuntu-latest
40-
# node: latest
37+
- os: ubuntu-latest
38+
node: latest
4139
fail-fast: false
4240

4341
runs-on: ${{ matrix.os }}

ark/attest/__tests__/assertions.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { attest } from "@ark/attest"
2-
import { MissingSnapshotError } from "@ark/attest/internal/assert/assertions.js"
3-
import { attestInternal } from "@ark/attest/internal/assert/attest.js"
2+
import { MissingSnapshotError } from "@ark/attest/internal/assert/assertions.ts"
3+
import { attestInternal } from "@ark/attest/internal/assert/attest.ts"
44
import { type } from "arktype"
55
import * as assert from "node:assert/strict"
66

ark/attest/__tests__/externalSnapshots.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { attest, contextualize } from "@ark/attest"
2-
import { attestInternal } from "@ark/attest/internal/assert/attest.js"
2+
import { attestInternal } from "@ark/attest/internal/assert/attest.ts"
33
import { dirName, readJson, writeJson } from "@ark/fs"
44
import * as assert from "node:assert/strict"
55
import { rmSync } from "node:fs"

ark/attest/__tests__/satisfies.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { attest, contextualize } from "@ark/attest"
2-
import { nonOverlappingSatisfiesMessage } from "@ark/attest/internal/assert/chainableAssertions.js"
2+
import { nonOverlappingSatisfiesMessage } from "@ark/attest/internal/assert/chainableAssertions.ts"
33

44
contextualize(() => {
55
it("can assert types", () => {

ark/attest/__tests__/unwrap.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { attest, contextualize } from "@ark/attest"
2-
import type { Completions } from "@ark/attest/internal/cache/writeAssertionCache.js"
2+
import type { Completions } from "@ark/attest/internal/cache/writeAssertionCache.ts"
33
import type { autocomplete } from "@ark/util"
44

55
contextualize(() => {

ark/attest/config.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,16 @@ let cachedConfig: ParsedAttestConfig | undefined
195195

196196
export const getConfig = (): ParsedAttestConfig => parseConfig()
197197

198+
// workaround for a bug in Node 25 that creates localStorage as an empty proxy,
199+
// leading to @typescript/vfs eventually throwing when it sees that it is not
200+
// undefined and tries to call `getItem`:
201+
202+
// https://github.com/nodejs/node/issues/60303
203+
204+
// this can be removed once the bug is addressed in Node
205+
if (!globalThis.localStorage?.getItem)
206+
globalThis.localStorage = undefined as never
207+
198208
export const ensureCacheDirs = (): void => {
199209
cachedConfig ??= getConfig()
200210
ensureDir(cachedConfig.cacheDir)

ark/attest/package.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ark/attest",
3-
"version": "0.51.0",
3+
"version": "0.52.0",
44
"license": "MIT",
55
"author": {
66
"name": "David Blass",
@@ -20,9 +20,13 @@
2020
"ark-ts": "./index.ts",
2121
"default": "./out/index.js"
2222
},
23-
"./internal/*": {
24-
"ark-ts": "./*",
25-
"default": "./out/*"
23+
"./internal/*.ts": {
24+
"ark-ts": "./*.ts",
25+
"default": "./out/*.js"
26+
},
27+
"./internal/*.js": {
28+
"ark-ts": "./*.ts",
29+
"default": "./out/*.js"
2630
}
2731
},
2832
"files": [

ark/docs/components/AutoplayDemo.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,10 @@ export const AutoplayDemo = (props: AutoplayDemoProps) => {
6464
ref={videoRef}
6565
autoPlay
6666
loop
67-
controls={true}
67+
controls
6868
playsInline
6969
muted
70-
disablePictureInPicture={true}
70+
disablePictureInPicture
7171
style={{ width: "100%", display: "block", margin: "0 auto" }}
7272
{...props}
7373
/>

ark/docs/components/ReleaseBanner.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
import { usePathname } from "next/navigation.js"
44
import { Banner } from "./Banner.tsx"
55

6-
const text = "📈 Announcing ArkType 2.1 📈"
6+
const text = "🎉 Introducing arkregex 🎉"
77

88
export const ReleaseBanner = () => (
99
<Banner
10-
id="2.1"
11-
href="/docs/blog/2.1"
10+
id="arkregex"
11+
href="/docs/blog/arkregex"
1212
style={{ fontSize: 16 }}
1313
boat={usePathname().includes("docs")}
1414
>

ark/docs/components/dts/regex.ts

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)