66651
๐Ÿ‘€
66651
  • ๋ถ„๋ฅ˜ ์ „์ฒด๋ณด๊ธฐ (57)
    • note (28)
    • log (13)
    • error (9)
    • etc (7)

๋ธ”๋กœ๊ทธ ๋ฉ”๋‰ด

  • ํ™ˆ
  • ํƒœ๊ทธ
  • ๋ฐฉ๋ช…๋ก

ํ‹ฐ์Šคํ† ๋ฆฌ

hELLO ยท Designed By ์ •์ƒ์šฐ.
66651

๐Ÿ‘€

error

[JS] e.touches[0] ์—์„œ Uncaught TypeError: Cannot read property '0' of undefined ์—๋Ÿฌ

e.touches[0].clientX ๋ฅผ e.touches && e.touches[0].clientX ๋กœ ๋ณ€๊ฒฝ

e.touches[0].clientX || e.clientX;

↓

(e.touches && e.touches[0].clientX) || e.clientX;

 

 

stackoverflow.com/questions/38527202/mouse-and-touch-events-not-working-as-expected

 

Mouse and Touch events not working as expected

I'm trying to add a mouse and touch down and move event. In the events function, I want to get the clientX amount. I did the following to get it: console.log(e.touches[0].clientX || e.clientX); B...

stackoverflow.com

์ €์ž‘์žํ‘œ์‹œ (์ƒˆ์ฐฝ์—ด๋ฆผ)
    'error' ์นดํ…Œ๊ณ ๋ฆฌ์˜ ๋‹ค๋ฅธ ๊ธ€
    • [Webpack] Cannot find module 'sass' ์—๋Ÿฌ
    • [Gulp] Task never defined: default ์˜ค๋ฅ˜
    • [JS] DevTools failed to load source map: … ๊ฒฝ๊ณ  ์ง€์šฐ๊ธฐ
    • [jQuery] Uncaught TypeError: url.indexOf is not a function ์—๋Ÿฌ
    66651
    66651
    always awake

    ํ‹ฐ์Šคํ† ๋ฆฌํˆด๋ฐ”