@playfast/reform-proof-vitest 1.0.2 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +19 -19
  2. package/src/plugin.ts +2 -7
package/package.json CHANGED
@@ -1,35 +1,37 @@
1
1
  {
2
2
  "name": "@playfast/reform-proof-vitest",
3
- "playbook": "./playbook",
4
- "version": "1.0.2",
5
- "type": "module",
3
+ "version": "1.1.0",
6
4
  "description": "Vitest adapter for reform-proof — a vite plugin that auto-registers every *.proof.ts suite as native vitest tests, run through the proof engine.",
7
5
  "keywords": [
8
- "reform",
9
6
  "effect",
10
- "testing",
11
7
  "proof",
8
+ "reform",
9
+ "testing",
12
10
  "vitest"
13
11
  ],
12
+ "bugs": {
13
+ "url": "https://github.com/playfast/reform/issues"
14
+ },
14
15
  "license": "MIT",
15
16
  "repository": {
16
17
  "type": "git",
17
18
  "url": "https://github.com/playfast/reform.git",
18
19
  "directory": "packages/reform-proof-vitest"
19
20
  },
20
- "bugs": {
21
- "url": "https://github.com/playfast/reform/issues"
22
- },
21
+ "files": [
22
+ "src",
23
+ "README.md"
24
+ ],
25
+ "type": "module",
23
26
  "sideEffects": false,
24
27
  "exports": {
25
28
  "./package.json": "./package.json",
26
29
  ".": "./src/index.ts",
27
30
  "./*": "./src/*.ts"
28
31
  },
29
- "files": [
30
- "src",
31
- "README.md"
32
- ],
32
+ "publishConfig": {
33
+ "access": "public"
34
+ },
33
35
  "scripts": {
34
36
  "clean": "rm -rf dist .tsbuildinfo",
35
37
  "check": "tsc --noEmit",
@@ -42,14 +44,12 @@
42
44
  "dependencies": {
43
45
  "es-module-lexer": "^1.5.4"
44
46
  },
45
- "peerDependencies": {
46
- "vitest": "*",
47
- "@playfast/reform-proof": "*"
48
- },
49
47
  "devDependencies": {
50
48
  "@playfast/reform-proof": "*"
51
49
  },
52
- "publishConfig": {
53
- "access": "public"
54
- }
50
+ "peerDependencies": {
51
+ "@playfast/reform-proof": "*",
52
+ "vitest": "*"
53
+ },
54
+ "playbook": "./playbook"
55
55
  }
package/src/plugin.ts CHANGED
@@ -9,17 +9,12 @@ export interface ReformProofPluginOptionsExternalApi {
9
9
  export interface ReformProofPluginExternalApi {
10
10
  readonly name: string
11
11
  readonly enforce: 'post'
12
- transform(
13
- code: string,
14
- id: string,
15
- ): Promise<{ readonly code: string; readonly map: null } | null>
12
+ transform(code: string, id: string): Promise<{ readonly code: string; readonly map: null } | null>
16
13
  }
17
14
 
18
15
  const sourcePath = (id: string): string => id.replace(/\?.*$/, '')
19
16
 
20
- const setupList = (
21
- setup: ReformProofPluginOptionsExternalApi['setup'],
22
- ): ReadonlyArray<string> =>
17
+ const setupList = (setup: ReformProofPluginOptionsExternalApi['setup']): ReadonlyArray<string> =>
23
18
  setup === undefined ? [] : typeof setup === 'string' ? [setup] : setup
24
19
 
25
20
  export const reformProofPlugin = (