Skip to content

[IDEA] Second argument to [subfilter[]] to set currentTiddler #9217

@flibbles

Description

@flibbles

The title says it all. I'm doing some pretty heavy filter work for TW5-Graph stuff, and my filters would be tremendously simpler if I could just set currentTiddler when I invoke the subfilter operator.

Currently, I'm doing stuff like this:

[<someValue>] :map:flat[subfilter<myFilter>]

Which is very suboptimal. :map:flat insists on returning something even if the filter returns nothing, which is an annoying thing to work around. And sometimes I'm finding I need to double-nest :map:flat calls just to get currentTiddler equal to what I need. See the lunacy that my <$nodes.neighbors> macro is becoming.

I'd really love to be able to just do this:

[<someValue>subfilter<myFilter>,<someValue>]

and be done with it. I could make the PR and tests if necessary.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions