/ ^ ([a murz] +\.?) + [a-z0-9] + $/

/^([a-z]+\.?)+[a-z0-9]+$/

what is the meaning of this escape


this expression can cause serious backtracking in some cases, such as
[hint that if the following code is run directly in the browser, it may cause the browser to crash]

/^([a-z]+\.?)+[a-z0-9]+$/.test("a.b.b.b.b.c.d.s.d.s.e.f.sdf.s.sd.df.sd.ss.df.sd.sd.s.d.d.sdffdfsfd.sdfsadfjk.ksdjflkfdj.ksdjflfj.skdfdlfui.lk-");

it is recommended that you write this

^(?!.*\.\.)(?=[a-z])[a-z.]+[a-z0-9]+$

or

^[a-z]+(?:\.[a-z]+)*[a-z\d]*$

means to start with one or more letters, followed by a decimal point (with or without a decimal point), and then end with a letter or number.
recommend a website. Click into it and you will understand regexper.com

.
Menu