Share an auto-complete source code that I accidentally discovered. When testing here, we use an array. When actually using it, we can change it to the method of getting it from the server through Ajax and it will be OK.
Tip: You can save it directly to an html file to view the effect.