This prints null, but I would've expected the hyphen to match. What am I missing?
console.log(
JSON.stringify(/-/.exec("–"))
);
u/Gold_Mycologist5372 — 19 days ago
This prints null, but I would've expected the hyphen to match. What am I missing?
console.log(
JSON.stringify(/-/.exec("–"))
);