span class="octicon octicon-file-text"> 3394_fsm 058f31828c first commit před 1 rokem 3394_vm 058f31828c first commit před 1 rokem 3395 058f31828c first commit před 1 rokem 3429 058f31828c first commit před 1 rokem 3430 058f31828c first commit před 1 rokem 3431 058f31828c first commit před 1 rokem 3433 058f31828c first commit před 1 rokem 3439 058f31828c first commit před 1 rokem 3440 058f31828c first commit před 1 rokem 3455 058f31828c first commit před 1 rokem 3456 058f31828c first commit před 1 rokem 3456_fsm 058f31828c first commit před 1 rokem 3456_vm 058f31828c first commit před 1 rokem 3466 058f31828c first commit před 1 rokem 3467 058f31828c first commit před 1 rokem 3468 058f31828c first commit před 1 rokem 3501 058f31828c first commit před 1 rokem 3502 058f31828c first commit před 1 rokem 3503 058f31828c first commit před 1 rokem 3534 058f31828c first commit před 1 rokem 3541 058f31828c first commit před 1 rokem 3541_fsm 058f31828c first commit před 1 rokem 3541_vm 058f31828c first commit před 1 rokem 3542 058f31828c first commit před 1 rokem 3574 058f31828c first commit před 1 rokem 3575 058f31828c first commit před 1 rokem 3576 058f31828c first commit před 1 rokem 3596 058f31828c first commit před 1 rokem 3597 058f31828c first commit před 1 rokem 3598 058f31828c first commit před 1 rokem 3599 058f31828c first commit před 1 rokem 3600 058f31828c first commit před 1 rokem 3600_fsm 058f31828c first commit před 1 rokem 3600_vm 058f31828c first commit před 1 rokem 3601 058f31828c first commit před 1 rokem 3601_fsm 058f31828c first commit před 1 rokem 3601_vm 058f31828c first commit před 1 rokem 3602 058f31828c first commit před 1 rokem 3602_fsm 058f31828c first commit před 1 rokem 3602_vm 058f31828c first commit před 1 rokem 3603 058f31828c first commit před 1 rokem 3603_fsm 058f31828c first commit před 1 rokem 3603_vm 058f31828c first commit před 1 rokem 3604 058f31828c first commit před 1 rokem 3605 058f31828c first commit před 1 rokem 3606 058f31828c first commit před 1 rokem 3607 058f31828c first commit před 1 rokem 3608 058f31828c first commit před 1 rokem 3609 058f31828c first commit před 1 rokem 3712 058f31828c first commit před 1 rokem 3764 058f31828c first commit před 1 rokem 3764_fsm 058f31828c first commit před 1 rokem 3764_vm 058f31828c first commit před 1 rokem 3766 058f31828c first commit před 1 rokem 3767 058f31828c first commit před 1 rokem 3997 058f31828c first commit před 1 rokem 4143 058f31828c first commit před 1 rokem 4144 058f31828c first commit před 1 rokem 4145 058f31828c first commit před 1 rokem 4146 058f31828c first commit před 1 rokem 4147 058f31828c first commit před 1 rokem 4148 058f31828c first commit před 1 rokem 4149 058f31828c first commit před 1 rokem 4150 058f31828c first commit před 1 rokem 4151 058f31828c first commit před 1 rokem 4152 058f31828c first commit před 1 rokem 4153 058f31828c first commit před 1 rokem 4154 058f31828c first commit před 1 rokem 4155 058f31828c first commit před 1 rokem 4156 058f31828c first commit před 1 rokem 4157 058f31828c first commit před 1 rokem 4158 058f31828c first commit před 1 rokem 4159 058f31828c first commit před 1 rokem 4160 058f31828c first commit před 1 rokem 4161 058f31828c first commit před 1 rokem 4162 058f31828c first commit před 1 rokem 4163 058f31828c first commit před 1 rokem 4164 058f31828c first commit před 1 rokem 4165 058f31828c first commit před 1 rokem 4166 058f31828c first commit před 1 rokem 4167 058f31828c first commit před 1 rokem 4168 058f31828c first commit před 1 rokem 4169 058f31828c first commit před 1 rokem 4170 058f31828c first commit před 1 rokem 4171 058f31828c first commit před 1 rokem 4172 058f31828c first commit před 1 rokem 4173 058f31828c first commit před 1 rokem 4174 058f31828c first commit před 1 rokem 5002 058f31828c first commit před 1 rokem 548 058f31828c first commit před 1 rokem 549 058f31828c first commit před 1 rokem 6102 058f31828c first commit před 1 rokem 6104 058f31828c first commit před 1 rokem 6106 058f31828c first commit před 1 rokem 6110 058f31828c first commit před 1 rokem 6111 058f31828c first commit před 1 rokem 6112 058f31828c first commit před 1 rokem 6113 058f31828c first commit před 1 rokem 6117 058f31828c first commit před 1 rokem 826 058f31828c first commit před 1 rokem 827 058f31828c first commit před 1 rokem 828 058f31828c first commit před 1 rokem PG_VERSION 058f31828c first commit před 1 rokem pg_filenode.map 058f31828c first commit před 1 rokem tum/tmt_learning - Gogs: Simplico Git Service

Keine Beschreibung

Prach Pongpanich 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren
..
LICENSE 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren
README.md 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren
index.d.ts 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren
index.js 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren
package.json 6f337d0a21 install tailwind alpine daisyui vor 2 Jahren

README.md

anymatch Build Status Coverage Status

Javascript module to match a string against a regular expression, glob, string, or function that takes the string as an argument and returns a truthy or falsy value. The matcher can also be an array of any or all of these. Useful for allowing a very flexible user-defined config to define things like file paths.

Note: This module has Bash-parity, please be aware that Windows-style backslashes are not supported as separators. See https://github.com/micromatch/micromatch#backslashes for more information.

Usage

npm install anymatch

anymatch(matchers, testString, [returnIndex], [options])

  • matchers: (Array|String|RegExp|Function) String to be directly matched, string with glob patterns, regular expression test, function that takes the testString as an argument and returns a truthy value if it should be matched, or an array of any number and mix of these types.
  • testString: (String|Array) The string to test against the matchers. If passed as an array, the first element of the array will be used as the testString for non-function matchers, while the entire array will be applied as the arguments for function matchers.
  • options: (Object [optional]_) Any of the picomatch options.
    • returnIndex: (Boolean [optional]) If true, return the array index of the first matcher that that testString matched, or -1 if no match, instead of a boolean result.
const anymatch = require('anymatch');

const matchers = [ 'path/to/file.js', 'path/anyjs/**/*.js', /foo.js$/, string => string.includes('bar') && string.length > 10 ] ;

anymatch(matchers, 'path/to/file.js'); // true
anymatch(matchers, 'path/anyjs/baz.js'); // true
anymatch(matchers, 'path/to/foo.js'); // true
anymatch(matchers, 'path/to/bar.js'); // true
anymatch(matchers, 'bar.js'); // false

// returnIndex = true
anymatch(matchers, 'foo.js', {returnIndex: true}); // 2
anymatch(matchers, 'path/anyjs/foo.js', {returnIndex: true}); // 1

// any picomatc

// using globs to match directories and their children
anymatch('node_modules', 'node_modules'); // true
anymatch('node_modules', 'node_modules/somelib/index.js'); // false
anymatch('node_modules/**', 'node_modules/somelib/index.js'); // true
anymatch('node_modules/**', '/absolute/path/to/node_modules/somelib/index.js'); // false
anymatch('**/node_modules/**', '/absolute/path/to/node_modules/somelib/index.js'); // true

const matcher = anymatch(matchers);
['foo.js', 'bar.js'].filter(matcher);  // [ 'foo.js' ]
anymatch master* ❯

anymatch(matchers)

You can also pass in only your matcher(s) to get a curried function that has already been bound to the provided matching criteria. This can be used as an Array#filter callback.

var matcher = anymatch(matchers);

matcher('path/to/file.js'); // true
matcher('path/anyjs/baz.js', true); // 1

['foo.js', 'bar.js'].filter(matcher); // ['foo.js']

Changelog

See release notes page on GitHub

License

ISC