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

created debug credentials provider #68

Merged
merged 5 commits into from
Dec 27, 2022

Conversation

yk
Copy link
Collaborator

@yk yk commented Dec 26, 2022

if DEBUG_FAKE_USERS is set, a credentials provider for next auth is created that lets one log in with an arbitrary username and always get accepted. this simplifies the experience for newcomers who just want to e.g. create a UI component.

Co-authored-by: Ville Lahdenvuo <tuhoojabotti@gmail.com>
Copy link
Collaborator

@fozziethebeat fozziethebeat left a comment

Choose a reason for hiding this comment

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

I like this, I didn't notice that provider.

I proposed two small alternatives to smooth out the setup process.

@@ -32,6 +34,23 @@ if (process.env.DISCORD_CLIENT_ID) {
);
}

if (boolean(process.env.DEBUG_FAKE_USERS)) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should we just do this whenever we're running in development mode? If so we could cut out a new env variable and make this

if (process.env.NODE_ENV === "development") {

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

that's a great idea. I've pushed a change for this and adjusted documentation

website/README.md Outdated Show resolved Hide resolved
yk and others added 2 commits December 27, 2022 13:57
Co-authored-by: Ville Lahdenvuo <tuhoojabotti@gmail.com>
@yk yk merged commit c70c9d1 into main Dec 27, 2022
@yk yk deleted the 66-create-a-set-of-fake-default-users-for-the-website branch December 27, 2022 13:01
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.

Create a set of fake default users for the website
3 participants