Skip to content
  • Vincent's avatar
    Adding basic authentication functionality · f42f8ae6
    Vincent authored
    To be able to write to a person's Pod, they need to log in and
    authorise our app. To do this, we use the React components in
    https://www.npmjs.com/package/@solid/react.
    
    Although it unfortunately comes with a bunch of stuff we will not
    be using, the authentication components are easy enough to use:
    wrap components that should be visible to people who are not
    logged in inside a <LoggedOut> component, and those that should
    only be visible to those who are logged in inside a <LoggedIn>.
    
    Actual authentication is initiated with a <LoginButton>.
    Unfortunately, at this time this involves including an HTML blob
    verbatim as downloaded from
    https://solid.github.io/solid-auth-client/dist/popup.html
    (this is linked to from the README of @solid/react). In the future,
    this will hopefully be properly packaged.
    f42f8ae6