Merge pull request #2875 from tridactyl/seturl_autocmd_link

Fix #2482: help people to find autocmd from seturl
This commit is contained in:
Oliver Blanthorn 2020-10-05 18:56:23 +01:00 committed by GitHub
commit 3dda2a8582
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -3476,6 +3476,8 @@ function validateSetArgs(key: string, values: string[]) {
* When multiple patterns can apply to a same URL, the pattern that has the highest priority is used. You can set the priority of a pattern by using `:seturl pattern priority 10`. By default every pattern has a priority of 10.
*
* Note that the patterns a regex-like, not glob-like. This means that if you want to match everything, you need to use `.*` instead of `*`.
*
* If you'd like to run an ex-command every time a page loads, see [[autocmd]] instead.
*/
//#content
export function seturl(pattern: string, key: string, ...values: string[]) {