Ordering Looped Results by Field's Numerical Value I’m looping through some text fields on the form results page and need to order the numerical output from low to high.

How would I do this using twig?

{% for field in submission %}
  {% submission[field.handle].value %}
{% endfor %}


Note: I am using the Freeform Plugin. They have informed me that I would need to create a custom filter but before I do that wanted to see if there was a better way to do this.
It's an extra plugin but SuperSort would do the job - https://github.com/TopShelfCraft/SuperSort

Edit - couldn't make it work in one go, but this works:

{% set results = [] %}
{% for field in submission %}
  {% set results = results | merge([{'handle': field.handle, 'value': submission[field.handle].value}]) %}
{% endfor %}
{% set sortedResults = results | supersort('sortAs', '{value}', SORT_NUMERIC) %}


Not the most elegant, let me know if you find a better solution!