Sort order of Templates in the composer

Discourse 2025.12.0-latest, Discourse Templates 2.5.0

Composer → Insert template

The templates are displayed in a “random” order – neither alphabetically nor by timestamp – which makes selecting a template harder than necessary.

Feature request:

Make the template list in the composer sortable.

:slight_smile:  

additional note:

The templates were displayed in alphabetical order before. The actual “random” order appeared with the recent update.

1 Like

Looks like the sort order was changed so that the most used templates appear at the top, in UX: Improve template filtering with usage count and preserving tags by Alteras1 · Pull Request #35881 · discourse/discourse · GitHub… but there’s no indication of this, so it can certainly appear random, especially if you were accustomed to the previous alphabetical ordering.

This isn’t a bug because it’s working as indented, so I’m going to move it to a feature request for more sorting options. Thanks for the feedback!

3 Likes

Imagine a heterogeneous team using different template classes. In that context, “most used” quickly becomes ambiguous – which is exactly the case in our use scenario.

The UX would be more satisfying if you either allowed a sorting option or, if you stick with the current heuristic, provided a way to limit the selection to specific template classes.

The template plugin already supports multiple categories for storing templates. This could be leveraged to implement the latter approach.

Thanks :slight_smile:

1 Like