Skip to content

Conversation

@1aishwaryasharma
Copy link

Fix incorrect property name in Auth0Options interface

Changes

Fixed a typo in the Auth0Options interface where the property name was incorrectly using PascalCase (LocalAuthenticationOptions) instead of camelCase (localAuthenticationOptions).

What changed:

  • Updated src/types/common.ts line 96: Changed LocalAuthenticationOptions?: LocalAuthenticationOptions; to localAuthenticationOptions?: LocalAuthenticationOptions;

Why this is important:

  • The incorrect property name was inconsistent with:
    • The comment on line 108 which references localAuthenticationOptions
    • The NativeAuth0Options interface which correctly extends Auth0Options with localAuthenticationOptions
    • All actual usage throughout the codebase which uses localAuthenticationOptions (camelCase)
  • This fix ensures type definitions match actual runtime behavior and prevents potential TypeScript errors when accessing this property

Impact:

  • This is a bug fix that corrects the type definition to match actual usage
  • No breaking changes - the property was already being used correctly in the codebase, only the type definition was wrong
  • Improves type safety and consistency

References

  • No external issues that I see reported. We faced this issue in our enterprise app today while implementing the local authentication

Testing

Test Results:

  • ✅ All existing tests pass: 361 tests passed across 25 test suites
  • ✅ No linting errors introduced
  • ✅ TypeScript compilation successful

How to test:

  1. Verify the type definition in src/types/common.ts uses localAuthenticationOptions (camelCase)
  2. Run yarn test - all tests should pass
  3. Run yarn lint - no new errors should be introduced
  4. Verify TypeScript compilation with yarn typecheck - should complete without errors

What was tested:

  • All existing unit tests pass without modification

  • Type definitions are now consistent with actual usage

  • No breaking changes introduced

  • This change adds unit test coverage

  • This change has been tested on the latest version of the platform/language or why not

    • All tests pass with existing test suite. No new tests needed as this is a bug fix correcting existing type definitions.

Checklist

@1aishwaryasharma 1aishwaryasharma requested a review from a team as a code owner November 8, 2025 04:29
@subhankarmaiti
Copy link
Contributor

Hi @1aishwaryasharma
Thanks for the findings and for opening the PR. However, we won’t be able to merge it now as it introduces breaking changes. We’ll keep this open and plan to include it in the next major release.

@1aishwaryasharma
Copy link
Author

1aishwaryasharma commented Nov 8, 2025

@subhankarmaiti do you mind expanding on how this is breaking change for my understanding? It's just the type file. There are no runtime code changes. The runtime code has always used localAuthenticationOptions (camelCase). The type definition incorrectly allowed LocalAuthenticationOptions (PascalCase), which would fail at runtime.

@subhankarmaiti
Copy link
Contributor

Thanks @1aishwaryasharma
I was looking at it wrong, Let me check if it could impact anywhere else.

@1aishwaryasharma 1aishwaryasharma force-pushed the bugfix/fix-incorrect-type-definition-Auth0Options branch from 2b12a5f to 3cb6863 Compare November 8, 2025 05:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants