JavaScript RegExp global property
- Previous Page constructor
- Next Page ignoreCase
- Go to the Previous Level JavaScript RegExp Reference Manual
Definition and usage
global
The property specifies whether the 'g' modifier is set.
If set "g" modifier, then this property returns true
, otherwise returns false
.
Description
The RegExp object's global
The property is a read-only boolean value.
It specifies whether the regular expression performs a global match, such as whether the flag g was used when it was created.
Syntax
regexp.global
Return value
Type | Description |
---|---|
Boolean value | Returns true if the 'g' modifier is set, otherwise returns false. |
Browser support
global
It is a feature of ECMAScript1 (ES1).
All browsers fully support ES1 (JavaScript 1997):
Chrome | IE | Edge | Firefox | Safari | Opera |
---|---|---|---|---|---|
Support | Support | Support | Support | Support | Support |
- Previous Page constructor
- Next Page ignoreCase
- Go to the Previous Level JavaScript RegExp Reference Manual