Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,18 @@ on:
paths:
- "src/**"
- "!src/docs/**"
- "./.github/workflows/build_and_test.yml"
- ".agents/**"
- ".opencode/**"
- ".github/workflows/build_and_test.yml"

# run it during pull request
pull_request:
paths:
- "src/**"
- "!src/docs/**"
- "./.github/workflows/build_and_test.yml"
- ".agents/**"
- ".opencode/**"
- ".github/workflows/build_and_test.yml"

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down
13 changes: 9 additions & 4 deletions .github/workflows/build_and_test_sample_ts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ on:
branches: [main]
paths:
- "samples/simple-ts/**"
- "./.github/workflows/build_and_test_sample_ts.yml"
- ".github/workflows/build_and_test_sample_ts.yml"

# run it during pull request
pull_request:
paths:
- "samples/simple-ts/**"
- "./.github/workflows/build_and_test_sample_ts.yml"
- ".github/workflows/build_and_test_sample_ts.yml"

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand All @@ -21,6 +21,9 @@ defaults:
run:
working-directory: samples/simple-ts

permissions:
contents: read

jobs:
build-and-test-code:
name: Build sample code
Expand All @@ -29,12 +32,14 @@ jobs:

steps:
- name: Check Out Repo
uses: actions/checkout@v6
uses: actions/checkout@v7

- name: Use Node.js
uses: actions/setup-node@v6
uses: actions/setup-node@v7
with:
node-version-file: ./samples/simple-ts/.nvmrc
cache: npm
cache-dependency-path: samples/simple-ts/package-lock.json

- name: Install dependencies
run: npm ci
Expand Down
12 changes: 3 additions & 9 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,10 @@
"files.eol": "\n",

"typescript.preferences.importModuleSpecifier": "relative",
"js/ts.experimental.useTsgo": true,
"js/ts.tsdk.path": "./src/node_modules/@typescript/native",
"eslint.workingDirectories": [{ "mode": "auto" }],
"debug.javascript.terminalOptions": {
"nodeVersionHint": 24
},
"nodejs-testing.include": ["./**/**"],
"nodejs-testing.extensions": [
{
"extensions": ["ts", "mts"],
"filePatterns": ["**/*.spec.ts", "**/*.spec.mts"],
"parameters": ["--import", "tsx"]
}
]
}
}
5 changes: 3 additions & 2 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@
"kind": "build",
"isDefault": true
},
"problemMatcher": [],
"problemMatcher": ["$tsc-watch"],
"isBackground": true,
"label": "npm: build:ts:watch",
"detail": "tsc -b --watch",
"detail": "tsc -b tsconfig.json tsconfig.cloudflare.json --watch",
"options": {
"cwd": "${workspaceFolder}/src/"
}
Expand Down
3 changes: 2 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ We recommend using VSCode and installing the following extensions:

- [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint),
- [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode),
- [Vitest test runner](https://marketplace.visualstudio.com/items?itemName=connor4312.nodejs-testing)
- [TypeScript Native Preview](https://marketplace.visualstudio.com/items?itemName=TypeScriptTeam.native-preview),
- [Vitest test runner](https://marketplace.visualstudio.com/items?itemName=vitest.explorer)

This will ensure that all workspace settings around code style will be automatically applied.

Expand Down
2 changes: 1 addition & 1 deletion samples/cloudflare/d1/.nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v24.12.0
v24.22.1
1 change: 1 addition & 0 deletions samples/cloudflare/d1/.vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"recommendations": [
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",
"TypeScriptTeam.native-preview",
"vitest.explorer"
]
}
7 changes: 6 additions & 1 deletion samples/cloudflare/d1/.vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,10 @@
{
"mode": "auto"
}
]
],
"js/ts.experimental.useTsgo": true,
"js/ts.tsdk.path": "./node_modules/@typescript/native",
"debug.javascript.terminalOptions": {
"nodeVersionHint": 24
}
}
5 changes: 3 additions & 2 deletions samples/cloudflare/d1/.vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@
"kind": "build",
"isDefault": true
},
"problemMatcher": [],
"problemMatcher": ["$tsc-watch"],
"label": "npm: build:ts:watch",
"detail": "tsc -b --watch"
"detail": "tsc -b --watch",
"isBackground": true
},
{
"type": "npm",
Expand Down
Loading
Loading