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.

Can't get it to work in pure JS

See original GitHub issue

import * as arrive from 'arrive/src/arrive.js';

$(document).arrive('.smthing', () => { console.log('bla'); }); works document.arrive('.smthing', () => { console.log('bla'); }); doesn’t work

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:22 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
uzairfarooqcommented, Mar 26, 2020

Oh, you didn’t in the fiddle. I assumed you copied mine.

@narcolepticinsomniac when you are using arrow function you cannot use this because arrow functions does not allow binding this. You can use the passed param as in the js fiddle.

0reactions
uzairfarooqcommented, Jun 20, 2020

This seems like an issue with typescirpt type declaration so closing it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Pure Js onclick element doesn't work - Stack Overflow
I'm having trouble when i run this code under greasemonkey the last position working and run function. var arry = []; arry =...
Read more >
Handling common JavaScript problems - MDN Web Docs
Now we'll look at common cross-browser JavaScript problems and how to fix them. This includes information on using browser dev tools to track ......
Read more >
Making your JavaScript Pure - A List Apart
For a function to be strictly pure, it has to only use variables supplied by it's input, it can't modify the variables it...
Read more >
pure.js - Javascript Template Engine
We have been happily using pure.js since 2008 for our own web app, ... If the function returns true the item is kept,...
Read more >
Pure Functions in JS: Avoiding Unwanted Problems
All in all, pure functions provide 3 major levels of benefits: You get fewer unexpected bugs, thus making your code a lot more...
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