// Copyright 2009 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.


'javascript/examples'
This directory contains files related to using the examples from JavaScript.
For the shared examples files, see top-level directory 'examples'.


1. Files for the simple example:

+ simple_generated.js
    The JS file generated by SoyToJsSrcCompiler when it is executed on simple.soy.
    Note: For an example that generates this file, please see exec-maven-plugin execution
    'js-simple-example' in the 'pom.xml'.

+ simple-usage.js
    Hand-written JS code that uses the generated functions.

+ simple-usage.html
    Basic HTML code that ties it all together and displays the result. Note that the generated
    code requires the library 'javascript/soyutils.js'.


2. Files for the features example:

+ features-usage_globals.txt
    Compile-time globals file for the features examples. This is passed as an optional flag to
    SoyToJsSrcCompiler.

+ simple_generated_en.js, features_generated_en.js,
  simple_generated_x-zz.js, features_generated_x-zz.js
    The JS files generated by SoyToJsSrcCompiler when it is executed on simple.soy and
    features.soy (locales are 'en' and 'x-zz' with the translated XLIFF files from shared examples
    directory 'examples' and with the above compile-time globals file). We need both simple.soy and
    features.soy because some of the templates in features.soy call the templates in simple.soy.
    Note: For an example that generates these files, please see exec-maven-plugin execution
    'js-features-example' in the 'pom.xml'.

+ features-usage.js
    Hand-written JS code that uses the generated functions.

+ features-usage_en.html, features-usage_x-zz.html
    Basic HTML code that ties it all together and displays the result. Note that the generated
    code requires the library 'javascript/soyutils.js'.
