Hello,
I have an idea to deprecate a feature in exchange for better performance. Currently, there are predefined tags that are replaced by default inside the loop, like {TITLE}
and {IMAGE_ID}
.
[loop type="post"]
Predefined: {TITLE} and {IMAGE_ID}
[/loop]
This feature must perform a search for all predefined tags (about a dozen), for every loop – which is not so efficient.
The change I’m thinking of making is, that only tags which are defined by the fields parameter will be replaced.
[loop type="post" fields="id, image-id"]
Specified by fields: {ID} and {IMAGE-ID}
Not specified, will not replace: {TITLE}
[/loop]
This will be breaking backward compatibility, but it would cut down on unnecessary search-and-replace.
I remembered this patch request, so wanted to ask your opinion. Are you still using field tags? If so, could you recommend a good way to deprecate the predefined tags being replaced by default? I just didn’t want to make a change that would affect any running shortcodes that rely on this feature.