Movatterモバイル変換


[0]ホーム

URL:


  1. 개발자를 위한 웹 기술
  2. JavaScript
  3. JavaScript 참고서
  4. JavaScript error reference
  5. TypeError: "x" has no properties

This page was translated from English by the community.Learn more and join the MDN Web Docs community.

View in EnglishAlways switch to English

TypeError: "x" has no properties

nullundefined 라는 속성에 접근하려고 시도할때 "null(혹은 undefined)은 속성이 없습니다"라는 JavaScript 에러가 발생합니다.

메세지

TypeError: Cannot read properties of undefined (reading 'x') (V8-based)TypeError: null has no properties (Firefox)TypeError: undefined has no properties (Firefox)TypeError: undefined is not an object (evaluating 'undefined.x') (Safari)

에러 타입

TypeError.

무엇이 잘못되었을까?

nullundefined 에 접근 할 수 있는 속성이 없습니다.

예제

null and undefined have no properties

js
null.foo;// TypeError: null has no propertiesundefined.bar;// TypeError: undefined has no properties

참조

Help improve MDN

Learn how to contribute

This page was last modified on byMDN contributors.


[8]ページ先頭

©2009-2025 Movatter.jp