i am trying to display a message if a value in a user defined field matches the current tags in a tiddler , so one value in a field against multiple tag values in the same tiddler , what am i doing wrong here
In your posted code, you assign to testvariable, but the filter refers to thisvariable
In your 2nd $let widget, you used {{{ [<currentTiddler>tags[]] }}}, which could contain a list of tag values. However, when a “filtered transclusion” is used to set a value of a widget parameter, only the value of the first item in the filter results will be assigned to the parameter.
In my example code, the 2nd $let widget uses {{{ [<currentTiddler>get[tags]] }}}, which gets the tags field value as a single text string composed of space-separated tag values. Then, in the $list widget, we use enlist<testvariable2> to “unpack” the text string into separate items to look for a match with <testvariable>
In my example code, the 2nd $list widget demonstrate the use of the contains:tags... filter operator, which implicitly searches the currentTiddler’s list of tags for a matching value, without needing to directly retrieve the tags field value into testvariable2.