There is a line of text from various characters. You need to select all the characters except the first. Example:

there is an abcdef, you need to get bcdef .

    3 answers 3

    If you choose a capture group, then:

     /^.(.*)/ 

    If you just get a match from these characters, then:

     /(?!^).*/ 

       let str = 'abcdef,'; // Может не надо регулярок? console.info(str.substring(1)); // bcdef, // Но если очень надо... console.info(str.replace(/.(?=(.*))/, '')); // bcdef, 

        You can do the following:

         var text = 'bcdef'; var result = text.match(/^.(.*)$/); console.log(result[1]);