[PR #3769] [MERGED] fix: plugin option compatibility with ts-config on exposing options #21895

Closed
opened 2026-04-15 20:40:58 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/3769
Author: @Kinfe123
Created: 8/3/2025
Status: Merged
Merged: 8/4/2025
Merged by: @Bekacru

Base: canaryHead: fix/plugin-option-with-ts-config


📝 Commits (3)

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 packages/better-auth/src/types/plugins.ts (+1 -1)

📄 Description

Since most Better Auth plugins don’t expose options, this flag had no effect in many cases , but for plugins like jwt, organization, and others that do expose options, it caused type errors due to the stricter handling of undefined set on tsconfig like exactOptionalPropertyTypes. Disabling the flag ensures consistent compatibility across all plugins without compromising type safety for now.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/3769 **Author:** [@Kinfe123](https://github.com/Kinfe123) **Created:** 8/3/2025 **Status:** ✅ Merged **Merged:** 8/4/2025 **Merged by:** [@Bekacru](https://github.com/Bekacru) **Base:** `canary` ← **Head:** `fix/plugin-option-with-ts-config` --- ### 📝 Commits (3) - [`bd54e59`](https://github.com/better-auth/better-auth/commit/bd54e59358028efb3e235f1bce954f6e85b2ae8c) tsconfig option - [`a349f5e`](https://github.com/better-auth/better-auth/commit/a349f5e7abd0ffdc8f62e41b108a2d2f37b782fa) Create odd-forks-fail.md - [`1c83f85`](https://github.com/better-auth/better-auth/commit/1c83f85b8532af33439567c46d22a802e76aa243) chore: remove changeset ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/types/plugins.ts` (+1 -1) </details> ### 📄 Description Since most Better Auth plugins don’t expose options, this flag had no effect in many cases , but for plugins like jwt, organization, and others that do expose options, it caused type errors due to the stricter handling of undefined set on tsconfig like `exactOptionalPropertyTypes`. Disabling the flag ensures consistent compatibility across all plugins without compromising type safety for now. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 20:40:58 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#21895