FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

feat: Migrate build to `@tanstack/config` and common Nx config (#1037) · evdeveloper/Tanstack-Router-@5596fcb · GitHub

Commit 5596fcb

Browse files
feat: Migrate build to @tanstack/config and common Nx config (TanStack#1037)
* Root level and example changes * Fix non-workspace links * Rework scripts directory * Change package build, tsconfig, exports * Fix cli package * Run prettier format * Update github workflows * Update repository field * Slight package.json reorder * Remove unused dependencies * Small vite/tsconfig tweaks * Remove unnecessary config * Add @ts-check to generate.js * Fix pnpm-workspace * Update Nx * Update workspace links
1 parent 3d2d96a commit 5596fcb

138 files changed

Lines changed: 2067 additions & 4197 deletions

File tree

Some content is hidden

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

‎.browserslistrc‎

Lines changed: 0 additions & 7 deletions
This file was deleted.

‎.github/workflows/ci.yml‎

Lines changed: 25 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,54 @@
11
name: ci
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
tag:
7+
description: override release tag
8+
required: false
9+
push:
10+
branches: ['main', 'alpha', 'beta']
11+
212
concurrency:
3-
group: publish-${{ github.github.base_ref }}
13+
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
414
cancel-in-progress: true
15+
516
env:
6-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
717
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
8-
on:
9-
push:
10-
branches:
11-
- 'main'
12-
- 'beta'
18+
NX_CLOUD_AUTH_TOKEN: ${{ secrets.NX_CLOUD_AUTH_TOKEN }}
19+
1320
jobs:
1421
test-and-publish:
15-
name: 'Test & Publish'
22+
name: Test & Publish
23+
if: github.repository == 'TanStack/router'
1624
runs-on: ubuntu-latest
1725
steps:
1826
- name: Checkout
1927
uses: actions/checkout@v4
2028
with:
21-
fetch-depth: 0
29+
fetch-depth: '0'
2230
- name: Setup pnpm
2331
uses: pnpm/action-setup@v2
2432
with:
2533
version: 8
2634
- name: Setup Node
2735
uses: actions/setup-node@v4
2836
with:
29-
node-version-file: '.nvmrc'
30-
cache: 'pnpm'
37+
node-version-file: .nvmrc
38+
cache: pnpm
3139
- name: Install dependencies
32-
run: pnpm --filter "./packages/**" --prefer-offline install --no-frozen-lockfile
40+
run: pnpm install --frozen-lockfile --prefer-offline
41+
- name: Run Tests
42+
run: pnpm run test:ci
3343
- name: Publish
3444
run: |
3545
git config --global user.name 'Tanner Linsley'
3646
git config --global user.email 'tannerlinsley@users.noreply.github.com'
3747
npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
38-
pnpm cipublish
48+
pnpm run cipublish
3949
env:
4050
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
4151
GH_TOKEN: ${{ secrets.GH_TOKEN }}
52+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4253
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
54+
TAG: ${{ inputs.tag }}

‎.github/workflows/pr.yml‎

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,23 @@
11
name: pr
2-
on: [pull_request]
2+
3+
on:
4+
pull_request:
5+
paths-ignore:
6+
- 'docs/**'
7+
- 'media/**'
8+
- '**/*.md'
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
12+
cancel-in-progress: true
13+
314
env:
4-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
515
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
16+
NX_CLOUD_AUTH_TOKEN: ${{ secrets.NX_CLOUD_AUTH_TOKEN }}
17+
618
jobs:
719
test:
8-
name: 'Test'
20+
name: Test
921
runs-on: ubuntu-latest
1022
steps:
1123
- name: Checkout
@@ -19,9 +31,13 @@ jobs:
1931
- name: Setup Node
2032
uses: actions/setup-node@v4
2133
with:
22-
node-version-file: '.nvmrc'
23-
cache: 'pnpm'
34+
node-version-file: .nvmrc
35+
cache: pnpm
2436
- name: Install dependencies
25-
run: pnpm --filter "./packages/**" --prefer-offline install --no-frozen-lockfile
26-
- name: Build & Test
27-
run: npx nx run-many --targets=test,build --projects=@tanstack/*
37+
run: pnpm install --frozen-lockfile --prefer-offline
38+
- name: Get base and head commits for `nx affected`
39+
uses: nrwl/nx-set-shas@v3
40+
with:
41+
main-branch-name: 'main'
42+
- name: Run Checks
43+
run: pnpm run test:pr

‎.gitignore‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ types
99
build
1010
*/build
1111
dist
12+
.output
1213
lib
1314
es
1415
artifacts
@@ -51,4 +52,7 @@ nx-cloud.env
5152
.vscode
5253
.nx
5354

54-
gpt/db.json
55+
gpt/db.json
56+
57+
vite.config.js.timestamp-*
58+
vite.config.ts.timestamp-*

‎.npmrc‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
//registry.npmjs.org/:_authToken=${NPM_TOKEN}
2-
3-
# Note, the settings in this file are ignored by pnpm if the NPM_TOKEN env variable is not set...
4-
# https://github.com/pnpm/pnpm/issues/5914
5-
auto-install-peers=false
1+
prefer-workspace-packages=true

‎.prettierignore‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
**/.next
2+
**/.nx/cache
3+
**/.svelte-kit
4+
**/build
5+
**/coverage
6+
**/dist
7+
**/docs
8+
pnpm-lock.yaml

‎babel.config.js‎

Lines changed: 0 additions & 33 deletions
This file was deleted.

‎examples/react/basic-default-search-params/index.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />

‎examples/react/basic-default-search-params/package.json‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
},
1111
"dependencies": {
1212
"@tanstack/react-query": "^5.17.8",
13-
"@tanstack/react-router": "1.7.1",
14-
"@tanstack/router-devtools": "1.7.1",
13+
"@tanstack/react-router": "^1.7.1",
14+
"@tanstack/router-devtools": "^1.7.1",
1515
"axios": "^1.6.5",
1616
"react": "^18.2.0",
1717
"react-dom": "^18.2.0"

‎examples/react/basic-file-based-codesplitting/index.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!doctype html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL