I’m trying to find a way to pick up values set by <button> or <select>-<option> tags (or JS variables generated from the values) and use them inside Hugo template code. The purpose would be to use such values as a MATCH value for where function.
Hugo is a static site generator. So your HTML gets generated before your JS ever fires. So you can pass values to JS from your templates, but not the other way around.