Javascript error in chrome console, in my Web App

Hello,


I get the following javascript error when filling out a form, the form is filled correctly without errors. Does anyone know the cause?


Regards,

Josep,

The error message "Uncaught TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.says that the value supplied to the parameter 1 is not an element, possibly a collection of elements. Can you check the piece of code where the error log is pointing?

Regards,

Swatantra

Hi Josep,

As suggested by Swatantra please share the oml code so that we can check on our end

Swatantra Kumar wrote:

Josep,

The error message "Uncaught TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.says that the value supplied to the parameter 1 is not an element, possibly a collection of elements. Can you check the piece of code where the error log is pointing?

Regards,

Swatantra

Hi, I can't find the getComputedStyle, what is it? I attached screenshot.


Hi Josep,

getComputedStyle is a Javascript method returns an object containing the values of all CSS properties of an element, So please check in your code that you have provided CSS element to this method.

E.g. Window.getComputedStyle('h1');// will return the properties of h1 like font-size, font-weight

Regards,

Krushna