JavaScriptRegExpグローバル
例
let pattern = /W3S/g;
let result = pattern.global;
ブラウザのサポート
global
ECMAScript1(ES1)機能です。
ES1(JavaScript 1997)は、すべてのブラウザーで完全にサポートされています。
Chrome | IE | Edge | Firefox | Safari | Opera |
Yes | Yes | Yes | Yes | Yes | Yes |
構文
RegExpObject.global
戻り値
Type | Description |
---|---|
Boolean | Returns true if the "g" modifier is set, false otherwise |