Error: Expected a conditional expression and instead saw an assignment. (no-cond-assign)
const re = /<%([^%>]+)?%>/g;
let match;
while (match = re.exec('<%hello%> you <%!%>')) {
console.log(match);
}
Doing a while loop to reassign match, but getting no-cond-assign error. I can still get output without errors but what is the best way to correct the syntax? Thanks