Get to know MDN better
This page was translated from English by the community. Learn more and join the MDN Web Docs community.
This feature is well established and works across many devices and browser versions. It’s been available across browsers since 2020년 1월.
flags 접근자 속성은 현재 정규식 객체의 플래그를 나타냅니다.
RegExp.prototype.flags는 문자열입니다. flags 속성의 플래그는 왼쪽에서 오른쪽으로 알파벳 순으로 정렬됩니다(예를 들어 "dgimsuy"). 실제로 다른 플래그 접근자(hasIndices, global, 등등)를 하나씩 호출하고 결과를 연결합니다.
내장된 모든 함수는 개별 플래그 접근자를 읽는 대신 flags 속성을 읽습니다.
flags의 set 접근자는 정의되지 않았습니다. 이 속성을 직접 변경할 수 없습니다.
| ECMAScript® 2027 Language Specification # sec-get-regexp.prototype.flags |
Enable JavaScript to view this browser compatibility table.
This page was last modified on 2025년 2월 11일 by MDN contributors.
Your blueprint for a better internet.
Visit Mozilla Corporation’s not-for-profit parent, the Mozilla Foundation.
Portions of this content are ©1998–2026 by individual mozilla.org contributors. Content available under a Creative Commons license.