The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Data::Sah::Compiler::js - Compile Sah schema to JavaScript code

VERSION

This document describes version 0.57 of Data::Sah::Compiler::js (from Perl distribution Data-Sah), released on 2015-05-17.

SYNOPSIS

 # see Data::Sah

DESCRIPTION

Derived from Data::Sah::Compiler::Prog.

METHODS

new() => OBJ

$c->compile(%args) => RESULT

Aside from Prog's arguments, this class supports these arguments:

DEVELOPER NOTES

To generate expression code that says "all subexpression must be true", you can do:

 ARRAY.every(function(x) { return blah(x) })

which shortcuts to false after the first item failure.

To say "at least one subexpression must be true":

 !ARRAY.every(function(x) { return !blah(x) })

HOMEPAGE

Please visit the project's homepage at https://metacpan.org/release/Data-Sah.

SOURCE

Source repository is at https://github.com/sharyanto/perl-Data-Sah.

BUGS

Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=Data-Sah

When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.

AUTHOR

perlancar <perlancar@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2015 by perlancar@cpan.org.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.