question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Configurable authentication

See original GitHub issue

If the pusher js-client could take a function authAdapter returning a promise, then it could be left to the user to perform the authentication in any way fit (different endpoints, headers handling, withCredentials switch, etc).

Should solve https://github.com/pusher/pusher-js/issues/83 and https://github.com/pusher/pusher-js/issues/99.

new Pusher(apiKey, {
  authAdapter: function(channel, ...) {
    return Promise(resolve, reject) {
      // ...
    };
  },
  // other conf...
});

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:5
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
jackfranklincommented, May 9, 2016

Although I’d personally prefer promises, I would stick to callbacks given our commitment to supporting a bunch of older browsers as well as newer ones.

Or we could make it work with both and ask those who want to use Promises to provide their own polyfill.

Like the idea though 👍

2reactions
jpatel531commented, May 8, 2016

I like the idea. I might be sceptical about Promises as we’d have to add another dependency to polyfill older browsers. Auth adapters is definitely something we’d like to tackle after the coming release is out

Read more comments on GitHub >

github_iconTop Results From Across the Web

Configure Authentication Methods (Windows)
This procedure shows you how to configure the authentication methods that can be used by computers in an isolated domain or standalone ...
Read more >
Configure Authentication Settings - Stewardship Tier Help
To configure a user account to use Anonymous authentication: Click Admin > Configuration > Parameters in the Navigation pane. Click the Security Settings...
Read more >
Configure Guardium Authentication
Click Setup > Tools and Views > Portal to open the Authentication Configuration. Select the Guardium radio button in the Authentication Configuration panel....
Read more >
Configure authentication methods
Configure authentication methods. This topic describes the authentication methods that can be used to authenticate to Privilege Cloud.
Read more >
Chapter 13. Configuring Authentication
In Red Hat Enterprise Linux, the Authentication Configuration Tool helps configure what kind of data store to use for user credentials, such as...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found