Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Replace deprecated React types, remove unnecessary imports #72

Merged
merged 6 commits into from
Oct 28, 2024

Conversation

ZeroWave022
Copy link
Member

  • Replaces React.ElementRef with React.ComponentRef, as it's marked as deprecated in @types/react@19
  • Replaces React imports with imports of functions being used. Types are automatically imported.

@ZeroWave022
Copy link
Member Author

Not sure why the CI can't find a module, would appreciate it if you took a look at it

@michaelbrusegard
Copy link
Member

Not sure why the CI can't find a module, would appreciate it if you took a look at it

It is because you updated lucia auth and in the newer version (since lucia is deprecated) oslo is now a separate package

package.json Outdated
"lucide-react": "^0.396.0",
"next": "15.0.1",
"next": "^15.0.2-canary.9",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"next": "^15.0.2-canary.9",
"next": "^15.0.1",

Dont use canary version for next use the stable version. React uses release candidate because it is required in the stable Next15 version

@michaelbrusegard
Copy link
Member

michaelbrusegard commented Oct 28, 2024

"@oslojs/crypto": "^1.0.1",
"@oslojs/encoding": "^1.1.0",

We need at least these two I think. And we also need the oath2 for feide: oslo/oauth2

bun add @oslojs/crypto @oslojs/encoding @oslo/oauth2

should fix it

@ZeroWave022
Copy link
Member Author

ZeroWave022 commented Oct 28, 2024

The code for Feide is not compatible with the new @oslojs packages, so that'll need to be fixed in a separate PR. Pinned Lucia's version for now instead.
Since Lucia is getting deprecated in march 2025, do we have any plan for a replacement?

@michaelbrusegard
Copy link
Member

The code for Feide is not compatible with the new @oslojs packages, so that'll need to be fixed in a separate PR. Pinned Lucia's version for now instead. Since Lucia is getting deprecated in march 2025, do we have any plan for a replacement?

Im implementing auth manually using the guides from lucia author. That is the fix :)

@michaelbrusegard michaelbrusegard merged commit 4560e47 into dev Oct 28, 2024
5 checks passed
@michaelbrusegard michaelbrusegard deleted the react-fixes branch October 28, 2024 23:47
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