File tree Expand file tree Collapse file tree 1 file changed +33
-33
lines changed Expand file tree Collapse file tree 1 file changed +33
-33
lines changed Original file line number Diff line number Diff line change 11name : CI
22
33on :
4- push :
5- branches : [ main ]
6- pull_request :
7- branches : [ main ]
4+ push :
5+ branches : [main]
6+ pull_request :
7+ branches : [main]
88
99jobs :
10- build-and-test :
11- runs-on : ubuntu-latest
12-
13- strategy :
14- matrix :
15- node-version : [16 .x, 18 .x, 20 .x]
16-
17- steps :
18- - uses : actions/checkout@v3
19-
20- - name : Use Node.js ${{ matrix.node-version }}
21- uses : actions/setup-node@v3
22- with :
23- node-version : ${{ matrix.node-version }}
24- cache : ' npm'
25-
26- - name : Install dependencies
27- run : npm ci
28-
29- - name : Build
30- run : npm run build
31-
32- - name : Test
33- run : npm test
34-
35- - name : Verify dual module compatibility
36- run : |
37- node -e "require('./dist/index.js')" # Test CJS
38- node --input-type=module -e "import * as mod from './dist/index.mjs'; console.log(typeof mod.convertJsonSchemaToZod === 'function')" # Test ESM
10+ build-and-test :
11+ runs-on : ubuntu-latest
12+
13+ strategy :
14+ matrix :
15+ node-version : [18 .x, 20 .x, 22 .x]
16+
17+ steps :
18+ - uses : actions/checkout@v3
19+
20+ - name : Use Node.js ${{ matrix.node-version }}
21+ uses : actions/setup-node@v3
22+ with :
23+ node-version : ${{ matrix.node-version }}
24+ cache : " npm"
25+
26+ - name : Install dependencies
27+ run : npm ci
28+
29+ - name : Build
30+ run : npm run build
31+
32+ - name : Test
33+ run : npm test
34+
35+ - name : Verify dual module compatibility
36+ run : |
37+ node -e "require('./dist/index.js')" # Test CJS
38+ node --input-type=module -e "import * as mod from './dist/index.mjs'; console.log(typeof mod.convertJsonSchemaToZod === 'function')" # Test ESM
You can’t perform that action at this time.
0 commit comments