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.

'[object NodeList]' is not a valid argument for 'Function.prototype.apply'

See original GitHub issue

Hello (:

First of all thank you for your great work!

In our Sentry we see an exception connected to your library so I am posting it here:

'[object NodeList]' is not a valid argument for 'Function.prototype.apply' (evaluating 'a.rootElement.querySelectorAll('[data-cssvars="out"]')')
second argument to Function.prototype.apply must be an array (https://cdnjs.cloudflare.com/ajax/libs/css-vars-ponyfill/2.4.3/css-vars-ponyfill.min.js#8)

It appears mainly on Firefox (24) and (Mobile) Safari.

Cheers, Ben

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
bbuhlercommented, Mar 12, 2021

Hi @jhildenbiddle, I didn’t had the chance to reproduce and test your branch yet. I tried using Firefox 24 via Browserstack, but unfortunately the VM browser always became unresponsive and ultimately crashed.

I will give it another try next week.

0reactions
bbuhlercommented, Mar 17, 2021

Hi @jhildenbiddle, I was not able to reproduce the issue in a real browser. But as @tiperes mentioned it is reproducible with wkhtmltopdf CLI tool, so I tried with that and it looks like your changes resolves the issue.

Thank you (:

Read more comments on GitHub >

github_iconTop Results From Across the Web

Function.prototype.apply() - JavaScript - MDN Web Docs
The apply() method calls the specified function with a given this value, and arguments provided as an array (or an array-like object).
Read more >
Fix Function.apply to work with generic array-like object ...
Since I implement DOM4 mutation methods in IE6+ I have to path Function.prototype.apply to allow array-like object as a second parameter - link...
Read more >
13282 (QtWebKit -- TypeError: '[object Object]' is not a valid ...
QtWebKit -- TypeError: '[object Object]' is not a valid argument for 'Function.prototype.apply' (evaluating 'elem.nodeType') ...
Read more >
how can i use Function.prototype.call instead of apply?
apply (console, Array.prototype.slice.call(arguments)); should work fine. Are you sure it's not console.log you need to worry about? Do ...
Read more >
Function.prototype.apply() - Javascript - CodeProject Reference
An array-like object, specifying the arguments with which fun should be called, or null or undefined if no arguments should be provided to...
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