Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
cb9715f
Adopt Vite+
nstepien Apr 2, 2026
47001bc
readme
nstepien Apr 2, 2026
f25089b
fix install?
nstepien Apr 2, 2026
4e14eb7
tweak cache
nstepien Apr 2, 2026
58b42d9
Merge remote-tracking branch 'origin/main' into viteplus
nstepien Oct 3, 2026
fc38095
reset all
nstepien Oct 3, 2026
29b9012
can use iterator.join() in chrome/firefox
nstepien Oct 3, 2026
45052b6
add devEngines.packageManager, bump devEngines.runtime, add allowScripts
nstepien Oct 3, 2026
82e89fc
configure js/ts.tsdk.path
nstepien Oct 3, 2026
3804643
tweak command syntax
nstepien Oct 3, 2026
f03349f
delete CLAUDE.md
nstepien Oct 3, 2026
65ab217
migrate
nstepien Oct 3, 2026
8d8bb2b
ignore a couple md rules
nstepien Oct 3, 2026
abecf41
vitest/browser -> vite-plus/test/browser
nstepien Oct 3, 2026
b662cdd
uninstall @tsdown/css
nstepien Oct 3, 2026
2bc508e
update subdeps
nstepien Oct 3, 2026
0e59484
scripts -> tasks
nstepien Oct 3, 2026
f55e6a1
remove typeCheck
nstepien Oct 3, 2026
d557468
noEmit
nstepien Oct 3, 2026
51ce875
update ci.yml
nstepien Oct 3, 2026
50955fd
use exact version
nstepien Oct 3, 2026
df6bedf
update other workflows
nstepien Oct 3, 2026
be35919
lint:md -> eslint
nstepien Oct 3, 2026
650bba1
tweak dependabot
nstepien Oct 3, 2026
0bad5fc
vitest/globals -> vite-plus/test/globals
nstepien Oct 3, 2026
4f22de7
tweaks
nstepien Oct 3, 2026
3ef4bd9
use lazyPlugins
nstepien Oct 3, 2026
35f1827
add pre-commit hooks, run eslint on md files change
nstepien Oct 3, 2026
f04ae24
revert `declare module` changes
nstepien Oct 3, 2026
7b60566
update AGENTS.md
nstepien Oct 3, 2026
d452eeb
review workflows
nstepien Oct 3, 2026
6dac72f
add ci task, cache in CI
nstepien Oct 4, 2026
5136656
resolve task caching issues
nstepien Oct 4, 2026
be76fee
do not import the tsr plugin in tests
nstepien Oct 4, 2026
1d958c6
enable coverage only in the CI workflow
nstepien Oct 4, 2026
2e533e5
resolve another task cache issue
nstepien Oct 4, 2026
e4fe920
add comment
nstepien Oct 4, 2026
33050e6
fix typo
nstepien Oct 4, 2026
0069fc9
force colors
nstepien Oct 4, 2026
48208c4
review dependabot
nstepien Oct 4, 2026
a4ec3f0
enable deps caching
nstepien Oct 4, 2026
cfe0e7a
dedupe playwright deps install in tasks
nstepien Oct 4, 2026
3c18f48
merge the visual test project into the browser project
nstepien Oct 4, 2026
373937c
fold the Vite+ agent instructions into AGENTS.md
nstepien Oct 4, 2026
89e66f0
fix coverage outside of CI
nstepien Oct 4, 2026
937da0b
quiet
nstepien Oct 4, 2026
9ed48e7
update badge URLs
nstepien Oct 4, 2026
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
5 changes: 5 additions & 0 deletions .github/apt.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// fail fast instead of hanging on unresponsive mirrors
Acquire::Retries "0";
Acquire::http::Timeout "10";
Acquire::https::Timeout "10";
quiet "2";
30 changes: 8 additions & 22 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,24 @@ updates:
directory: '/'
schedule:
interval: 'weekly'
# Vite+ and the packages it keeps aligned are updated with `vp migrate`:
# https://viteplus.dev/guide/upgrade-project
ignore:
- dependency-name: 'vite-plus'
- dependency-name: 'vite'
- dependency-name: '@voidzero-dev/*'
- dependency-name: 'vitest'
- dependency-name: '@vitest/*'
groups:
typescript:
patterns:
- 'typescript'
build-tooling:
patterns:
- 'vite'
- '@vitejs/*'
- 'vitest'
- 'vitest-*'
- '@vitest/*'
- 'tsdown'
- '@tsdown/*'
- 'playwright'
exclude-patterns:
- '@vitest/eslint-plugin'
quality:
patterns:
- 'eslint'
- '@eslint/*'
- 'oxfmt'
- 'oxlint'
- 'oxlint-*'
react:
patterns:
- 'react'
- 'react-dom'
- '@types/react'
- '@types/react-dom'
tanstack:
patterns:
- '@tanstack/*'
# everything else: single PR for minor/patch bumps,
# majors still land individually
dependencies:
Expand Down
120 changes: 73 additions & 47 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,80 +1,106 @@
name: CI

on:
push:
branches:
- main
pull_request:

permissions: {}

cache-mode: none

env:
FORCE_COLOR: 1

jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v7

- uses: actions/setup-node@v7
with:
node-version-file: 'package.json'
check-latest: true
permissions:
contents: read # check out the repository

- name: Install dependencies
run: npm ci
# restore and save the Vite Task cache
cache-mode: write

- name: Lint
run: |
node --run lint
node --run lint:md
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false

- name: Format
run: node --run format:check
- uses: voidzero-dev/setup-vp@3754dd7dbdb32bd8f6d28b6043de13ad3a75f21f # v1.21.1
with:
cache: true
cache-save: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
run-install: false

- name: Build lib
run: node --run build
- run: vp install --frozen-lockfile

- name: Build website
run: node --run build:website
# https://viteplus.dev/guide/github-actions-cache
- name: Restore Vite Task cache
id: vite-task-cache
uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: node_modules/.vite/task-cache
key: vite-task-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}-${{ github.run_attempt }}
restore-keys: vite-task-${{ runner.os }}-${{ runner.arch }}-

- name: Check routeTree.gen.ts
run: git diff --exit-code website/routeTree.gen.ts
# Vite Task compares directory listings with those recorded after the cached run,
# so directories created during the run must exist upfront for the cache to hit:
# https://github.com/voidzero-dev/vite-task/issues/504
- run: mkdir lib coverage node_modules/.vite-temp

- name: Install Playwright Browsers
run: |
sudo tee /etc/apt/apt.conf.d/99-ci >/dev/null <<'EOF'
Acquire::Retries "0";
Acquire::http::Timeout "10";
Acquire::https::Timeout "10";
EOF
npx playwright install chromium firefox webkit --with-deps --no-shell
timeout-minutes: 2
- run: vp run -v ci
timeout-minutes: 6

- name: Test
run: node --run test:ci
timeout-minutes: 4
- name: Save Vite Task cache
if: success()
uses: actions/cache/save@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: node_modules/.vite/task-cache
key: ${{ steps.vite-task-cache.outputs.cache-primary-key }}

- name: Upload test failure artifacts
if: failure()
uses: actions/upload-artifact@v7
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: test-artifacts
path: .vitest/attachments/**
# `.vitest` is a hidden directory
include-hidden-files: true
if-no-files-found: ignore

- name: Upload coverage
uses: codecov/codecov-action@v7
uses: codecov/codecov-action@303a32d7a59b442fa8d48b6a1cc6825c09c847a5 # v7.1.1
with:
token: ${{ secrets.CODECOV_TOKEN }}

- name: Deploy gh-pages
- name: Upload website
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
git config --global user.email 'action@github.com'
git config --global user.name 'GitHub Action'
git fetch origin gh-pages
git worktree add gh-pages gh-pages
cd gh-pages
git rm -r .
mv ../dist/* .
touch .nojekyll
git add .
git commit -m "gh-pages deployment" || echo "Nothing to commit"
git push -f https://comcast:${{secrets.GITHUB_TOKEN}}@github.com/Comcast/react-data-grid.git
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
with:
path: dist

deploy:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
needs: test
runs-on: ubuntu-latest
timeout-minutes: 5

permissions:
pages: write # deploy to GitHub Pages
id-token: write # verify the deployment originates from this workflow

# one deployment at a time, never cancel one midway
concurrency:
group: pages
cancel-in-progress: false

environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

steps:
- id: deployment
uses: actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346 # v5.0.1
77 changes: 33 additions & 44 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,73 +8,62 @@ on:
required: true
type: string

permissions: {}

cache-mode: none

env:
FORCE_COLOR: 1

# never run two publishes at once, and never cancel one midway
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: false

jobs:
publish:
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
timeout-minutes: 10

permissions:
contents: write
id-token: write
contents: write # push the version tag and create the GitHub release
id-token: write # npm trusted publishing

env:
VERSION: ${{ inputs.version }}

steps:
- uses: actions/checkout@v7
# credentials are persisted to push the version tag
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0

- uses: actions/setup-node@v7
- uses: voidzero-dev/setup-vp@3754dd7dbdb32bd8f6d28b6043de13ad3a75f21f # v1.21.1
with:
node-version-file: 'package.json'
check-latest: true
run-install: false
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies
run: npm ci

- name: Lint
run: |
node --run lint
node --run lint:md

- name: Format
run: node --run format:check

- name: Build lib
run: node --run build

- name: Build website
run: node --run build:website

- name: Check routeTree.gen.ts
run: git diff --exit-code website/routeTree.gen.ts

- name: Install Playwright Browsers
run: |
sudo tee /etc/apt/apt.conf.d/99-ci >/dev/null <<'EOF'
Acquire::Retries "0";
Acquire::http::Timeout "10";
Acquire::https::Timeout "10";
EOF
npx playwright install chromium firefox webkit --with-deps --no-shell
timeout-minutes: 2

- name: Test
run: node --run test:ci
timeout-minutes: 4
- run: vp install --frozen-lockfile

# before `vp run ci`, so `vp pack` prefixes classes with the new version
- name: Update version
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com"
npm version ${{ inputs.version }}
git config user.name "$GITHUB_ACTOR"
git config user.email "$GITHUB_ACTOR_ID+$GITHUB_ACTOR@users.noreply.github.com"
npm version "$VERSION"

- run: vp run ci
timeout-minutes: 6

# https://docs.npmjs.com/trusted-publishers
- name: Publish to npm
run: npm publish --tag latest

- name: Push tag
run: git push origin v${{ inputs.version }}
run: git push origin "v$VERSION"

- name: Create GitHub Release
run: gh release create v${{ inputs.version }} --title "v${{ inputs.version }}" --generate-notes
run: gh release create "v$VERSION" --title "v$VERSION" --generate-notes
env:
GH_TOKEN: ${{ github.token }}
43 changes: 19 additions & 24 deletions .github/workflows/update-screenshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,60 +5,55 @@ on:
types: [labeled]
workflow_dispatch:

permissions: {}

cache-mode: none

env:
FORCE_COLOR: 1

jobs:
update-screenshots:
if: ${{ github.event.label.name == 'Update Screenshots' || github.event_name == 'workflow_dispatch' }}
runs-on: ubuntu-latest
timeout-minutes: 10

permissions:
contents: write
pull-requests: write
contents: write # push the new screenshots
pull-requests: write # remove the label

# one at a time per branch
concurrency:
group: update-screenshots@${{ github.head_ref }}
group: update-screenshots@${{ github.head_ref || github.ref }}
cancel-in-progress: true

steps:
- uses: actions/checkout@v7
# credentials are persisted to push the new screenshots
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
ref: ${{ github.head_ref }}

- uses: actions/setup-node@v7
- uses: voidzero-dev/setup-vp@3754dd7dbdb32bd8f6d28b6043de13ad3a75f21f # v1.21.1
with:
node-version-file: 'package.json'
check-latest: true
run-install: false

- name: Remove label
if: github.event_name == 'pull_request'
run: gh pr edit --remove-label 'Update Screenshots'
env:
GH_TOKEN: ${{ github.token }}

- name: Install dependencies
run: npm ci
- run: vp install --frozen-lockfile

- name: Install Playwright Browsers
run: |
sudo tee /etc/apt/apt.conf.d/99-ci >/dev/null <<'EOF'
Acquire::Retries "0";
Acquire::http::Timeout "10";
Acquire::https::Timeout "10";
EOF
npx playwright install chromium firefox webkit --with-deps --no-shell
timeout-minutes: 2
- run: rm -r test/**/screenshots/**

- name: Update screenshots
run: |
rm -r test/**/screenshots/**
node --run test:ci:update
- run: vp run test test/visual --update
timeout-minutes: 4

- name: Push new screenshots
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com"
git config user.name "$GITHUB_ACTOR"
git config user.email "$GITHUB_ACTOR_ID+$GITHUB_ACTOR@users.noreply.github.com"
git add "test/**/screenshots/**"
git diff-index --quiet HEAD || git commit -m "Update screenshots"
git push
Loading
Loading