css-element-queries icon indicating copy to clipboard operation
css-element-queries copied to clipboard

ElementQueries.listen() is not a function

Open Alpin52 opened this issue 4 years ago • 2 comments
trafficstars

Hello! I tried to put the code into my site. I ran npm install. It mentioned some packages are out of date. But I installed npm a month ago. When I included line var ElementQueries = require('css-element-queries-1.2.1/src/ElementQueries');

-- I encountered an error. So I had to change it to var ElementQueries = require(['css-element-queries-1.2.1/src/ElementQueries']);

After that I experience the following ERROR:

Uncaught TypeError: ElementQueries.listen is not a function

Alpin52 avatar Dec 01 '20 05:12 Alpin52

My code is at http://iancaple.ru/div.html

Alpin52 avatar Dec 01 '20 06:12 Alpin52

try using this: var ElementQueries = require('css-element-queries/src/ElementQueries');

kethan1 avatar Mar 04 '21 07:03 kethan1