WebAuthnLiveComponent - Passwordless Auth for LiveView Apps

Update

I have opened PR 37 with the primary goals of breaking apart the components and improving documentation.

This seemed more daunting than it turned out to be. I’m finding the separated components easier to understand and document, and I hope you agree.

  • The README now includes Mermaid diagrams illustrating how each component interacts with the client and parent LiveView.
  • Each component has more complete module documentation with standardized sections for assigns, events, and messages.
  • A new USAGE.md was added, and I plan on filling in more detail before closing the PR.

Feedback is welcome, so feel free to review the code and documentation to check for errors and clarity. I request that questions and comments for the PR be added to the PR instead of the forum for posterity.

What’s Next

You may notice that I’ve upgraded this repo from early alpha to early beta in the readme. The new design and documentation are key :smirk: to maintainability and adoption. Testing is also critical for a set of security-oriented components, and the modular design should make testing more straightforward than it would have been.

After this PR is merged, I plan to proceed with writing tests for each component. Last time I attempted to write tests, I discovered that there was little or no tooling for testing JS hooks. I believe the components may be tested using factories for users, user keys, and user tokens, but I’m not sure how to proceed with JS testing.

If you are interested in contributing to component and/or JS tests, let me know here or via DM so we can discuss. :pray:

5 Likes