JSFiddle - React, Tailwind, and code Playground

HTML

<input id="AnlNr">

JavaScript

var AnlNrTags = ["five", "six", "seven", "eight"];

jQuery("#AnlNr").autocomplete({
    source: AnlNrTags,
}).focus(function () {
    AnlNrTags = ["one", "two", "three", "four"];
    jQuery("#AnlNr").autocomplete('option', 'source', AnlNrTags);
});