November 2024 M T W T F S S 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
Tag Archives: identity-obj-proxy
Mocking the CSS webpack imports using identity-obj-proxy
I’m sure at some point you have encountered the SyntaxError: Unexpected token . error when preparing tests with Jest, it pointed at the dot of the CSS class name. ({“Object.“:function(module,exports,require,__dirname,__filename,global,jest){.my-class { ^ SyntaxError: Unexpected token . If you are familiar with it … Continue reading
Posted in JavaScript, ReactJS
Tagged css module, identity-obj-proxy, jest, testing
Comments Off on Mocking the CSS webpack imports using identity-obj-proxy