본문 바로가기

프로그래밍 공부/JavaScript

JavaScript - 브라우저 객체 모델 개요

브라우저 객체 모델(BOM, Browser Object Model)은 웹 브라우저와 관련된 객체의 집합을 의미하는 것이다. 대표적인 브라우저 객체 모델은 window, location, navigator, history, screen, 그리고 document 객체가 존재한다.

window 객체
location 객체 navigator 객체 history 객체 screen 객체 document 객체

보통 window 객체 안에 location 객체, navigator 객체, history 객체, screen 객체, 그리고 document 객체가 있는 관계를 가지는데, 더 세분하게 나누면 document 객체는 문서 객체 모델(DOM, Document Object Model)로 그 외에는 브라우저 객체 모델이라고 부르게 된다.

브라우저 객체 모델(BOM) 문서 객체 모델(DOM)
window 객체 document 객체
location 객체 navigator 객체 history 객체 screen 객체

모든 객체 모델의 각각의 관련된 부분은 아래와 같다.