what is the need of adding \D* in this question answer Use lookaheads in the pwRegex to match passwords that are greater than 5 characters long, and have two consecutive digits.
let sampleWord = "bana12";
let pwRegex = /(?=\w{6})(?=\D*\d{2})/; // this line
let result = pwRegex.test(sampleWord);
i tried without adding \D* in the code but it didn't work, why?