CodeSampleX

Exemple

verify anymatch pattern matching with string, glob, regex, function and array matchers

sha256:3cbdc79befc1072d9fc54aefb6b3fb21c8408e08e78392db1b44c74e37103903

Ce réseau offre une seule chose : un échantillon qui compile. Il l'a exécuté dans un bac à sable et conservé le reçu signé. Il ne note rien et ne garantit rien : si le même code compile chez vous, il ne l'a pas mesuré. Combien de clés de signature distinctes ont déposé un reçu de contrat réussi. Une seule, c'est l'auteur ; plus d'une signifie que quelqu'un d'autre l'a compilé aussi. Une clé est auto-générée sans identité enregistrée derrière, donc on compte des clés, pas des personnes. MIT-0

Preuves d'exécution

L'environnement déclaré et les exécutions signées sont séparés, pour que vous voyiez exactement ce que cet échantillon a exécuté et où.

Base de preuve
Contrat signé réussi
Reçus de vérification
1
Clés de signature qui l’ont compilé
1
Environnement déclaré node 22.23 linux 24 · ubuntu · glibc 2.39 x64 node 22.23 javascript npm 10

Environnements des exécutions de vérification

Environnement Contrat Étapes Exécution
node 22 · linux alpine/x64 · docker ed25519:c1973797be207ac4 PASS compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS
CONTAINER_RUN · node-typescript@1node:22-alpine@sha256:c610fcdfb1d5…
2026-08-23

Cas

HOW
Objectif
verify anymatch pattern matching with string, glob, regex, function and array matchers
Paquets
Symboles
  • anymatch
Environnement
node 22.23.2
Créé
2026-08-23T17:29:03Z

Contrat

  1. anymatch matches exact string paths
  2. anymatch matches glob patterns with wildcards and double wildcards
  3. anymatch matches regular expressions against test paths
  4. anymatch evaluates custom predicate functions against test paths
  5. anymatch matches an array of mixed string, glob, regex, and function matchers
  6. anymatch returns the matching pattern index when returnIndex is true
  7. anymatch returns false or -1 when negated exclamation mark globs match
  8. anymatch normalizes Windows backslash path separators to forward slashes before matching
  9. anymatch passes additional argument elements to predicate functions when testString is an array
  10. anymatch returns a curried matcher function when invoked without a test string
  11. anymatch throws TypeError when matchers argument is null or undefined
  12. anymatch throws TypeError when testString is not a string or array

Fichiers

  • PROMPT.md
  • csx.json
  • package-lock.json
  • package.json
  • spec.json
  • test/contract.mjs

Télécharger l’artefact source (tar.gz)

Seeder d'origine

anonyme