This is my least favorite change with 4.25 thus far. The Search widget has used "contains" logic for many years, and to suddenly change it up to "starts with" logic without some kind of means by which we can turn it on or off (like a configuration parameter or something) is a bit of a curveball out of nowhere.
Anyhow, the heart of the workaround I've devised for 4.25 intercepts the process where the associated layer's queryFeatures function is called, and "fixes" the where clause. It looks something like this:
var source = new LayerSearchSource(options);
source.layer.defaultQueryFeatures = source.layer.queryFeatures;
source.layer.queryFeatures = function(query) {
if ((query) && (typeof query.where == "string"))
query.where = query.where.replace(/ LIKE '/g, " LIKE '%");
return this.defaultQueryFeatures.apply(this, arguments);
};
Note that "LayerSearchSource" is esri/widgets/Search/LayerSearchSource. Note also that there are some unlikely cases where this could cause unintended side effects, because any time the layer's queryFeatures function is called, any instances of " LIKE '" in the query's where property will be changed to " LIKE '%"...so you might consider how the layer object is being used, and if other functionality executes LIKE-based queries.
My workaround for 3.42 is "somewhat" cleaner in that the where clause is only altered for queries executed by the widget itself:
var search = new Search(options, srcNode);
search._defaultWhereClause = search._whereClause;
search._whereClause = function() {
var wc = this._defaultWhereClause.apply(this, arguments);
return ((typeof wc == "string") ? wc.replace(/ LIKE '/g, " LIKE '%") : wc);
};