Skip to content

Instantly share code, notes, and snippets.

@m3l1nd4
Last active May 24, 2021 01:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save m3l1nd4/a1e3f515f2f6f3aa98c6b941c0be0b70 to your computer and use it in GitHub Desktop.
Save m3l1nd4/a1e3f515f2f6f3aa98c6b941c0be0b70 to your computer and use it in GitHub Desktop.
// Event Listeners
// Reload Home
$$(document).on('click', '.back-link', function () {
$$(document).on('page:init', '.page[data-name="home"]', function () {
window.location.reload();
});
});
// Get Data for Thread Details Page
$$(document).on('click', '.thread-details', function () {
const id = $$(this).data('thread-id');
setUpThreadDetails(id);
setUpComments(id);
newComment(id);
});
// Pop Up With Swipe To Close
const loginSwipeToClosePopup = app.popup.create({
el:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment