NAME
Data::Sah::Compiler::js - Compile Sah schema to JavaScript code
VERSION
This document describes version 0.26 of module Data::Sah::Compiler::js (in distribution Data-Sah), released on 2014-04-28.
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
Steven Haryanto <stevenharyanto@gmail.com>
COPYRIGHT AND LICENSE
This software is copyright (c) 2014 by Steven Haryanto.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.