sanic_auth
#1231
Replies: 1 comment
-
It would be nice to be able to protect a component, but anyway I found this example that might do the job with authentication. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
This probably doesn't have a solution considering the other discussions around authentications in the forums and that Django seems to be the way forward, but I can't find anything in the documentation regarding how to handle incoming request variables into @component, and this might apply to several backends, so here I go.
I tested to use sanic_auth, and it seems to work with @app.route but not with Reactpy's @component
Is there any way to pass the request variables into the @component?
If so, is it possible to use @auth.login_required after @component, or is there any other way to do it?
Below is some code and the error message "TypeError: HelloWorld() missing 1 required positional argument: 'request'"
Removing the @auth.login_required, and a webpage will render nicely with "Hello, world!"
Hoping for the best
:)
Beta Was this translation helpful? Give feedback.
All reactions