From a55b575e8089ee6cab7c5c262a7e6db55d0e34d6 Mon Sep 17 00:00:00 2001 From: Florian Merz Date: Thu, 11 Feb 2021 14:46:50 +0100 Subject: unslug es: move --- .../global_objects/regexp/rightcontext/index.html | 54 ++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 files/es/web/javascript/reference/global_objects/regexp/rightcontext/index.html (limited to 'files/es/web/javascript/reference/global_objects/regexp/rightcontext') diff --git a/files/es/web/javascript/reference/global_objects/regexp/rightcontext/index.html b/files/es/web/javascript/reference/global_objects/regexp/rightcontext/index.html new file mode 100644 index 0000000000..39530ee1b5 --- /dev/null +++ b/files/es/web/javascript/reference/global_objects/regexp/rightcontext/index.html @@ -0,0 +1,54 @@ +--- +title: RegExp.rightContext ($') +slug: Web/JavaScript/Referencia/Objetos_globales/RegExp/rightContext +translation_of: Web/JavaScript/Reference/Global_Objects/RegExp/rightContext +--- +
{{JSRef}} {{non-standard_header}}
+ +

La propiedad rightContext (No es estándar) es una propiedad estática y de solo lectura de expresiones regulares que contiene la subcadena que sigue a la coincidencia más reciente. el alias para esta propiedad es RegExp.$'.

+ +

Sintaxis

+ +
RegExp.rightContext
+RegExp["$'"]
+
+ +

Descripción

+ +

La propiedad rightContext es estática, no es una propiedad de un objeto de expresión regular individual. Debe usarse como RegExp.rightContextRegExp["$'"].

+ +

El valor de la propiedad rightContext es de solo lectura y se modifica cada que hay una coincidencia exitosa.

+ +

Tenga presente que no puede usar la abreviatura (RegExp.$'), porque el analizador espera una cadena de inicio, si lo hace optendra un error de sintaxis {{jsxref("SyntaxError")}} , para este caso, usted debe usar corchetes. consulte notación de paréntesis para acceso a la propiedad.

+ +

Ejemplos

+ +

Usando rightContext y $'

+ +
var re = /hola/g;
+re.test('hola mundo!');
+RegExp.rightContext; // " mundo!"
+RegExp["$'"];       // " mundo!"
+
+ +

Especificaciones

+ +

No estándar. No forma parte de ninguna especificación actual.

+ + + +
+ + +

{{Compat("javascript.builtins.RegExp.rightContext")}}

+
+ +

Ver también

+ + -- cgit v1.2.3-54-g00ecf