Skip to content

feat(solid): add solid.js logto sdk #949

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yefu24324
Copy link

Summary

add solid.js logto sdk

Testing

Local preview.

Checklist

  • .changeset
  • unit tests
  • integration tests
  • necessary TSDoc comments

I referenced React and rewrote the SDK for SolidJS. Please let me know if there are any issues with the code

Sorry, something went wrong.

@wangsijie
Copy link
Contributor

@yefu24324 you may need to run pnpm i in the project root, to update the lock file

export const baseUrl = window.location.origin;
export const redirectUrl = `${baseUrl}/callback`;

export const appId = 'hi9w1eijf2nlnuz88xjt6'; // Register the sample app in Logto dashboard
Copy link
Contributor

Choose a reason for hiding this comment

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

we can replace them with env variables.

Copy link
Member

@charIeszhao charIeszhao Apr 25, 2025

Choose a reason for hiding this comment

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

Or just consts with fake ID, like in the other samples. Not a big deal, though.

export default function Callback() {
const navigate = useNavigate();
const { isLoading } = useHandleSignInCallback(() => {
console.log("???")
Copy link
Contributor

Choose a reason for hiding this comment

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

It would be better to replace with more friendly message or delete it.

@charIeszhao
Copy link
Member

Hey @yefu24324, thank you for your contribution. We're really excited to see your PR.

While we are reviewing the code, could you please also complete the steps to sign your commits? You can follow the GitHub official guide and let us know if you have questions.

@yefu24324
Copy link
Author

Hey @yefu24324, thank you for your contribution. We're really excited to see your PR.

While we are reviewing the code, could you please also complete the steps to sign your commits? You can follow the GitHub official guide and let us know if you have questions.

Okay, I need to learn GPG,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants