[Web Clipper] Add meta variable-based template matching

Use case or problem

The Web Clipper now supports both URL and schema.org matching in a template.
Schema.org recipes are not available on every site, but meta variables seem to be more common.

In my case, I want to create several templates for GitHub,
one for repo home page, one for issues, and another for files in the source tree.

On GitHub, the meta:name:route-controller variable can be used to distinguish these pages.

Since we already have schema.org matching, could we add support for the meta variable-based matching?

Furthermore, is it possible to trigger a temalpte with a conjuction(/) of a list of filters?
Say, if the URL matches github.com and the route-controller is some specific value.

Proposed solution

Support template matching based on mata-variables.
Support triggering a template if multiple rules fire together.

Current workaround (optional)

Code the URL patterns in Regular Expression and use RegEx-based matching
But this is not always feasible and it’s really painful to write and inspect RegExes.

Sincerely
L.P.

I think bug reports and feature requests for the Obsidian clipper go on the GitHub page:

Both of those already exist, don’t they?

Oh, I didn’t even realize that the clipper is open-source and hosted on GitHub.
I am going to post an issue on the GitHub page.

Thank you very much.

Great, thanks. I’ve been busy and haven’t been following along with the clipper developments the past few weeks.

I’ll move this to Help for now.

Not really.

I skippped through the source code and verified that both have not been implemented yet.

Not this?

And https://github.com/ can be added as a template trigger.

Sorry, I have already checked both the documentation and the source code.

I’m sure that the meta variables can be used to populate a template’s content,
but not yet to trigger a template, which is I’m looking for.

1 Like

My error. Thanks for clarifying. :+1: