Render the HTML for autocomplete results server-side instead of in Javascript. This is cleaner than building HTML in Javascript, but it may hurt caching because the HTTP responses are larger. Fixes #4698: user autocomplete contains links to /posts Also fixes a bug where tag counts in the autocomplete menu were different from tag counts displayed elsewhere because of differences in rounding.
2 lines
77 B
Plaintext
2 lines
77 B
Plaintext
<%= render AutocompleteComponent.new(autocomplete_service: @autocomplete) %>
|