Finds all occurrences of from, and replace them with to.
from
to
@useCopy IList<T> replaceAll({required T from, required T to}) => map((element) => (element == from) ? to : element).toIList(config);