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.

Trigger logout by clicking button

See original GitHub issue

Hi there, Is there a way to trigger logout when the button is click…

<button v-on:click="logout">Logout</button>
<v-facebook-login
            app-id="0000000000455"
            @sdk-init="handleSdkInit"
            @connect="handleConnect"
            @logout="handleLogout"
            @click="handleClick"
          >
          </v-facebook-login>

As you can see, I have a logout button and I need to logout also the facebook when the button logout is click. Thanks.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:12 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
adi518commented, Feb 22, 2020

I just tried this and it works without any errors.

<form v-if="facebook.scope.logout" @submit="facebook.scope.logout">
  <button>logout</button>
</form>

See this: https://stackoverflow.com/a/6525818/4106263

1reaction
adi518commented, Feb 22, 2020

Decided to have a quick go. It wasn’t possible with ref, so I passed the scope object to the sdk-init event. Update to 1.5.0 and see updated docs for usage example. 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

PHP Logout on button click - html - Stack Overflow
I made a login function using PHP, I have a variable called '$loggedIn' in a php class. How would I set this to...
Read more >
how i show login page after clicking on logout button widget?
i have one mashup which is my login page and i want to open that login page after clicking on logout button widget....
Read more >
Force Logout on Back Button - MSDN - Microsoft
How can I force a user to logout when he press the browser back button ? ... You can capture the back button...
Read more >
Clicking the browser back button after logout - OutSystems
a workaround you can do is to redirect the user to a 'pre-logout' screen (remain there for a few seconds) before you send...
Read more >
When User clicks the back button force to logout like internet ...
locked. When User clicks the back button force to logout like internet banking appln. RRS feed · Archived Forums 461-480. > Web Forms...
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