Spaces:
Sleeping
Sleeping
Download gui/frontend/node_modules/ajv/lib/dot/pattern.jst from BrianLov/guiBackend: direct link, hf CLI and curl.
- Browser
- Download file 576 Bytes
-
https://huggingface.co/spaces/BrianLov/guiBackend/resolve/main/gui/frontend/node_modules/ajv/lib/dot/pattern.jst
- Command line
-
hf download hf://spaces/BrianLov/guiBackend/gui/frontend/node_modules/ajv/lib/dot/pattern.jst
-
curl -L -o pattern.jst https://huggingface.co/spaces/BrianLov/guiBackend/resolve/main/gui/frontend/node_modules/ajv/lib/dot/pattern.jst
576 Bytes
| {{# def.definitions }} | |
| {{# def.errors }} | |
| {{# def.setupKeyword }} | |
| {{# def.$data }} | |
| {{ | |
| var $regExpCode = it.opts.regExp ? 'regExp' : 'new RegExp'; | |
| }} | |
| {{? $isData }} | |
| var {{=$valid}} = true; | |
| try { | |
| {{=$valid}} = {{=$regExpCode}}({{=$schemaValue}}).test({{=$data}}); | |
| } catch(e) { | |
| {{=$valid}} = false; | |
| } | |
| if ({{# def.$dataNotType:'string' }} !{{=$valid}}) { | |
| {{??}} | |
| {{ | |
| var $regexp = it.usePattern($schema); | |
| }} | |
| if ({{# def.$dataNotType:'string' }} !{{=$regexp}}.test({{=$data}}) ) { | |
| {{?}} | |
| {{# def.error:'pattern' }} | |
| } {{? $breakOnError }} else { {{?}} | |