Title: Javascript error: Failed to execute &#8216;getComputedStyle&#8217; on &#8216;Window&#8217;
Last modified: January 3, 2018

---

# Javascript error: Failed to execute ‘getComputedStyle’ on ‘Window’

 *  Resolved [simooo](https://wordpress.org/support/users/simooo/)
 * (@simooo)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/)
 * Hi there,
 * Thanks for great looking plugin. I have recently started using it and am incorporating
   in a site I’ve just started building, but hit a snag that I can’t get past.
 * I’m getting the following JS error when loading my front page:
 *     ```
       Uncaught TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.
           at Object.getCurrentDeviceMode (frontend.min.js?ver=1.6.5:2)
           at u (frontend.min.js?ver=1.6.5:2)
           at HTMLDocument.init (frontend.min.js?ver=1.6.5:2)
           at i (jquery.js?ver=1.12.4:2)
           at Object.fireWith [as resolveWith] (jquery.js?ver=1.12.4:2)
           at Function.ready (jquery.js?ver=1.12.4:2)
           at HTMLDocument.K (jquery.js?ver=1.12.4:2)
       ```
   
 * However I don’t get the error when loading a single post, which is the only other
   implemented screen so far. On the front page are no actual posts at the moment,
   only static content.
 * Any ideas what could be going wrong? I’ve already tried deactivating all other
   plugins. Would greatly appreciate any help in getting past this.
 * Cheers!
 * Simon

Viewing 9 replies - 1 through 9 (of 9 total)

 *  Plugin Author [ArielK](https://wordpress.org/support/users/arielk-1/)
 * (@arielk-1)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9444710)
 * Hi [@simooo](https://wordpress.org/support/users/simooo/) This is something that
   has been fixed in the next version to be released tomorrow
 *  Thread Starter [simooo](https://wordpress.org/support/users/simooo/)
 * (@simooo)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9445914)
 * That’s great news, thanks so much!
 *  [sansitster](https://wordpress.org/support/users/sansitster/)
 * (@sansitster)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9448906)
 * Hi Team
 * I am still getting the same error and i am using the latest version of Elementor.
   Can you please help? The page is showing fine in edit mode with Elementor.
 *  [tf5_bassist](https://wordpress.org/support/users/tf5_bassist/)
 * (@tf5_bassist)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9477370)
 * I, too, am receiving this error. On version 1.7.2, and the error shows up in 
   the console. Currently, I’m assuming that this error is what is causing conflict
   with the map refresh on a directory plugin, as when Elementor is deactivated,
   the issue is resolved.
 *     ```
       jquery-migrate.min.js?ver=1.4.1:2 JQMIGRATE: Migrate is installed, version 1.4.1
       frontend.min.js?ver=1.7.2:2 Uncaught TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.
           at Object.getCurrentDeviceMode (frontend.min.js?ver=1.7.2:2)
           at u (frontend.min.js?ver=1.7.2:2)
           at HTMLDocument.init (frontend.min.js?ver=1.7.2:2)
           at i (jquery.js?ver=1.12.4:2)
           at Object.fireWith [as resolveWith] (jquery.js?ver=1.12.4:2)
           at Function.ready (jquery.js?ver=1.12.4:2)
           at HTMLDocument.K (jquery.js?ver=1.12.4:2)
       getCurrentDeviceMode @ frontend.min.js?ver=1.7.2:2
       u @ frontend.min.js?ver=1.7.2:2
       init @ frontend.min.js?ver=1.7.2:2
       i @ jquery.js?ver=1.12.4:2
       fireWith @ jquery.js?ver=1.12.4:2
       ready @ jquery.js?ver=1.12.4:2
       K @ jquery.js?ver=1.12.4:2
       ```
   
 * Details:
    WP 4.8.1 Elementor 1.7.2 Fullby Premium theme
 *  [hpbonifacio](https://wordpress.org/support/users/hpbonifacio/)
 * (@hpbonifacio)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9509333)
 * Hi Im having the same issue. I cant use my navigation menus once I activate my
   elementor plug in. please fix the issue.
 *  [Ashish Dung Dung](https://wordpress.org/support/users/ashishdungdung/)
 * (@ashishdungdung)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9715919)
 * I’m still facing this problem in the latest version.
    WP 4.9. Elementor: v1.8.5
   Theme: GeneratPress
 *  [cristianleon](https://wordpress.org/support/users/cristianleon/)
 * (@cristianleon)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9779102)
 * Hi, same error today..
 * frontend.min.js:2 Uncaught TypeError: Failed to execute ‘getComputedStyle’ on‘
   Window’: parameter 1 is not of type ‘Element’.
    at Object.getCurrentDeviceMode(
   frontend.min.js:2) at u (frontend.min.js:2) at HTMLDocument.init (frontend.min.
   js:2) at i (jquery.js:2) at Object.fireWith [as resolveWith] (jquery.js:2) at
   Function.ready (jquery.js:2) at HTMLDocument.K (jquery.js:2)
 *  [bigjosh61](https://wordpress.org/support/users/bigjosh61/)
 * (@bigjosh61)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9800995)
 * I’m getting a similar error on Fluida theme only when I run Elementor.
    I disabled
   all other plugins to make sure. When Elementor is activated the mobile menu does
   not work on the home page. It works on all other pages except the home page. 
   Running WP 4.9.1 with Fluida 1.3.6.1 and Elementor 1.8.11
 * Uncaught TypeError: Failed to execute ‘getComputedStyle’ on ‘Window’: parameter
   1 is not of type ‘Element’.
    at Object.getCurrentDeviceMode (frontend.min.js?
   ver=1.8.11:2) at u (frontend.min.js?ver=1.8.11:2) at HTMLDocument.init (frontend.
   min.js?ver=1.8.11:2) at i (jquery.js?ver=1.12.4:2) at Object.fireWith [as resolveWith](
   jquery.js?ver=1.12.4:2) at Function.ready (jquery.js?ver=1.12.4:2) at HTMLDocument.
   K (jquery.js?ver=1.12.4:2) getCurrentDeviceMode @ frontend.min.js?ver=1.8.11:
   2 u @ frontend.min.js?ver=1.8.11:2 init @ frontend.min.js?ver=1.8.11:2 i @ jquery.
   js?ver=1.12.4:2 fireWith @ jquery.js?ver=1.12.4:2 ready @ jquery.js?ver=1.12.4:
   2 K @ jquery.js?ver=1.12.4:2
 *  [FlickDevs](https://wordpress.org/support/users/flickdevs/)
 * (@flickdevs)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9822073)
 * frontend.min.js?ver=1.8.11:2 Uncaught TypeError: Failed to execute ‘getComputedStyle’
   on ‘Window’: parameter 1 is not of type ‘Element’.
    at Object.getCurrentDeviceMode(
   frontend.min.js?ver=1.8.11:2) at u (frontend.min.js?ver=1.8.11:2) at HTMLDocument.
   init (frontend.min.js?ver=1.8.11:2) at i (jquery.js?ver=1.12.4:2) at Object.fireWith[
   as resolveWith] (jquery.js?ver=1.12.4:2) at Function.ready (jquery.js?ver=1.12.4:
   2) at HTMLDocument.K

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Javascript error: Failed to execute ‘getComputedStyle’ on ‘Window’’ is
closed to new replies.

 * ![](https://ps.w.org/elementor/assets/icon-256x256.gif?rev=3444228)
 * [Elementor Website Builder - more than just a page builder](https://wordpress.org/plugins/elementor/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/elementor/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/elementor/)
 * [Active Topics](https://wordpress.org/support/plugin/elementor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/elementor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/elementor/reviews/)

## Tags

 * [javascript](https://wordpress.org/support/topic-tag/javascript/)

 * 9 replies
 * 9 participants
 * Last reply from: [FlickDevs](https://wordpress.org/support/users/flickdevs/)
 * Last activity: [8 years, 5 months ago](https://wordpress.org/support/topic/javascript-error-failed-to-execute-getcomputedstyle-on-window/#post-9822073)
 * Status: resolved