Skip to content
Open
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
18 changes: 9 additions & 9 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/config@2.3.1/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
"$schema": "https://unpkg.com/@changesets/config@2.3.1/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
}
5 changes: 5 additions & 0 deletions .changeset/strict-ts6-package-output.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"next-navigation-utils": major
---

Migrate the package build and test setup to TypeScript 6 while keeping strict deprecation checks. Require Next.js 15 or newer and fix the published output so ESM and CJS consumers resolve the exported entrypoints correctly.
6 changes: 2 additions & 4 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@
{
"name": "Node.js & TypeScript",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/typescript-node:4-22-bookworm",
"image": "mcr.microsoft.com/devcontainers/typescript-node:4-24-trixie",
"customizations": {
"vscode": {
"extensions": [
"GitHub.vscode-pull-request-github"
]
"extensions": ["GitHub.vscode-pull-request-github"]
}
}

Expand Down
52 changes: 39 additions & 13 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,42 @@ permissions:
contents: read
jobs:
Unit:
name: Unit Tests (Node ${{ matrix.node-version }}, Next.js ${{ matrix.nextjs-version }})
name: Unit Tests (Node ${{ matrix.node-version }}, Next.js ${{ matrix.nextjs-version }}, React ${{ matrix.react-version }})
runs-on: ${{ matrix.os }}
timeout-minutes: 15
strategy:
matrix:
node-version: [20,22]
nextjs-version: ['14.0.0', '14.2.30', '15.0.0', '15.3.4']
os: [ubuntu-latest]
exclude:
# Node 22 wasn't supported in early Next.js 14 versions
- node-version: 22
nextjs-version: '14.0.0'
include:
- node-version: 24
nextjs-version: '15.0.0'
react-version: '18.2.0'
react-types-version: '18'
os: ubuntu-latest
- node-version: 26
nextjs-version: '15.0.0'
react-version: '18.2.0'
react-types-version: '18'
os: ubuntu-latest
- node-version: 24
nextjs-version: '15.3.4'
react-version: '18.2.0'
react-types-version: '18'
os: ubuntu-latest
- node-version: 26
nextjs-version: '15.3.4'
react-version: '18.2.0'
react-types-version: '18'
os: ubuntu-latest
- node-version: 24
nextjs-version: '16.2.6'
react-version: '19.2.5'
react-types-version: '19'
os: ubuntu-latest
- node-version: 26
nextjs-version: '16.2.6'
react-version: '19.2.5'
react-types-version: '19'
os: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v5.0.0
Expand All @@ -33,18 +57,20 @@ jobs:
pnpm-lock.yaml
next-app-mock/pnpm-lock.yaml
- run: pnpm i && pnpm build
- name: Install Next.js version ${{ matrix.nextjs-version }}
- name: Install framework versions
run: |
cd next-app-mock
echo "Installing Next.js version ${{ matrix.nextjs-version }}"
pnpm add next@${{ matrix.nextjs-version }}
echo "Installed Next.js version:"
pnpm list next
pnpm add next@${{ matrix.nextjs-version }} react@${{ matrix.react-version }} react-dom@${{ matrix.react-version }}
pnpm add -D @types/react@${{ matrix.react-types-version }} @types/react-dom@${{ matrix.react-types-version }}
echo "Installed framework versions:"
pnpm list next react react-dom
- run: pnpm playwright install --with-deps
- run: pnpm test
env:
CI: true
NEXTJS_VERSION: ${{ matrix.nextjs-version }}
REACT_VERSION: ${{ matrix.react-version }}
NODE_VERSION: ${{ matrix.node-version }}
- uses: actions/upload-artifact@v7
with:
Expand Down Expand Up @@ -85,4 +111,4 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Success
run: echo "Ready to merge!"
run: echo "Ready to merge!"
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Converting between them while keeping type safety & avoiding brittle string fidd
- 🎯 **Type Safety** – Strong typing for parameters & return values
- 🪝 **React Hooks** – Extract & sync URL state with zero boilerplate
- 🔗 **Fluent Link Builder** – Immutable, chainable URL editing (relative & absolute)
- ⚡ **Next.js Native** – Designed for the App Router (14+ / 15+)
- ⚡ **Next.js Native** – Designed for the App Router (15+)
- 🎛️ **State Sync** – Debounced two‑way sync between input state & URL
- 🧪 **Deterministic** – Pure helpers for server & test environments
- 📦 **Tree Shakeable** – Modular exports for optimal bundle size
Expand Down Expand Up @@ -500,7 +500,7 @@ const [search, setSearch] = useParamState(categoryParam) // [string | null, (val

## Requirements

- Next.js 14+ / 15+
- Next.js 15+
- React 18+ / 19+
- TypeScript (recommended)

Expand Down
Loading
Loading