src/Expose/Converter/ConvertJS.php
public function convertFromJSUnicode($value)
    {
        $matches = array();
        preg_match_all('/\\\u[0-9a-f]{4}/ims', $value, $matches);
        if (!empty($matches[0])) {
            foreach ($matches[0] as $match) {
                $chr = chr(hexdec(substr($match, 2, 4)));
                $value = str_replace($match, $chr, $value);
            }
            $value .= "\n\u0001";
        }
        return $value;
    }
public function convertFromJSUnicode($value)
    {
        $matches = array();
        preg_match_all('/\\\u[0-9a-f]{4}/ims', $value, $matches);
        if (!empty($matches[0])) {
            foreach ($matches[0] as $match) {
                $chr = chr(hexdec(substr($match, 2, 4)));
                $value = str_replace($match, $chr, $value);
            }
            $value .= "\n\u0001";
        }
        return $value;
    }
public function convertFromJSUnicode ( $ value ) { $ matches = array ( ) ; preg_match_all ( '/\\\u[0-9a-f]{4}/ims' , $ value , $ matches ) ; if ( ! empty ( $ matches [ 0 ] ) ) { foreach ( $ matches [ 0 ] as $ match ) { $ chr = chr ( hexdec ( substr ( $ match , 2 , 4 ) ) ) ; $ value = str_replace ( $ match , $ chr , $ value ) ; } $ value .= "\n\u0001" ; } return $ value ; }
This method converts JS unicode code points to regular characters

@param string $value the value to convert
@return string
This method converts JS unicode code points to regular characters