d3b92593d5
- Create Axios-based API client with sources, jobs, and dashboard endpoints - Add responsive Layout component with navigation sidebar - Set up React Router with Dashboard, Backups, and Settings routes - Configure TanStack Query provider with default options - Use lucide-react for navigation icons
18 lines
405 B
JavaScript
18 lines
405 B
JavaScript
'use strict';
|
|
|
|
var callBound = require('call-bound');
|
|
var isRegex = require('is-regex');
|
|
|
|
var $exec = callBound('RegExp.prototype.exec');
|
|
var $TypeError = require('es-errors/type');
|
|
|
|
/** @type {import('.')} */
|
|
module.exports = function regexTester(regex) {
|
|
if (!isRegex(regex)) {
|
|
throw new $TypeError('`regex` must be a RegExp');
|
|
}
|
|
return function test(s) {
|
|
return $exec(regex, s) !== null;
|
|
};
|
|
};
|