Closed THuffam closed 3 years ago
@THuffam I think it's difficult to understand because you're new to both. All you have to do is fill out the config options and use the provider as described on usage:
class Login {
// use authenticate(providerName) to get third-party authentication
authenticate(name) {
return this.authService.authenticate(name)
.then(response => {
this.provider[name] = true;
});
}
}
Update: Would you be so kind as to write down the steps you took to get it set up for me? We could really use a document describing the steps from someone who's completely new to this! It would help new users a lot.
The documentation says the following:
At the time of writing this, it relies by default on the Auth0 Lock library, that handles both the UI and the logic for all the authentication tasks. You can load it by including a script tag directly in your index.html file, or alternatively with a loader of your choice.
I am using webpack, and had to do the following:
main.js
, I added import Auth0Lock from "auth0-lock";
configure
method, I had to add PLATFORM.global.Auth0Lock = Auth0Lock;
Is this normal, or am I overlooking something obvious?
That might be because of the way resources in the webpack config work. I'm not sure, I don't use webpack myself. Perhaps it can be solved using the config?
Could be. Anyway, that part seems to work. How is the callback URL handled? Do I need to create a handler for that myself?
I think that's in the docs?
I couldn't find it, but I might be blind on both eyes. :-)
@RWOverdijk, as far as I can see, the callback stuff isn't documented. Should it be handled by an Aurelia route?
@dabide I don't know to be honest. I've never used this part of the plugin. But it seems to me that you don't have to handle a thing, and you just use authenticate. Maybe someone on gitter has the answer
I am trying to get Auth0 and aurelia-authentication working (I'm new to both).. but I cannot make head or tail of the document https://aurelia-authentication.spoonx.org/auth0.html
It is making a lot of assumptions and/or is missing a lot of information.
Is there a working example somewhere - that would explain it much better. Thanks Tim