<commit_before># Ahead-of-Time (AOT) support with ngc (doc in progress)

*Prerequisites:* 

* [Java Development Kit 8](http://www.oracle.com/technetwork/java/javase/downloads/index.html)
* [Maven 3.3.3](https://maven.apache.org/download.cgi) 
* [Npm 3.x.x](https://nodejs.org/en/)

*Recommended read:*

* [AOT Cookbook from angular doc](https://angular.io/docs/ts/latest/cookbook/aot-compiler.html)

### Run these commands to generate and run an Angular 2.4.0 web app:

By default this project reverses a [sample database schema](https://github.com/jaxio/celerio-angular-quickstart/blob/master/quickstart-conf/01-create.sql).
You may of course [reverse your own database schema](#how-to-use-your-own-database).

> **Note**: Downloading Maven dependencies + JavaScript dependencies may be long, so please be patient the first time you run these commands.

    git clone https://github.com/jaxio/celerio-angular-quickstart.git
    cd celerio-angular-quickstart/quickstart
    mvn -Pdb,metadata,gen generate-sources
    cd src/main/webapp
    npm install
    npm install @angular/compiler-cli @angular/platform-server --save
    npm install rollup rollup-plugin-node-resolve rollup-plugin-commonjs rollup-plugin-uglify --save-dev
    node copy-dist-files
    npm run build:aot    
    cd ../../..
    mvn package
    cd target
    java -jar celerio-angular-quickstart.jar


Then open [http://localhost:8080/](http://localhost:8080/)<commit_msg>AOT support doc<commit_after># Ahead-of-Time (AOT) support with ngc (doc in progress)

*Prerequisites:* 

* [Java Development Kit 8](http://www.oracle.com/technetwork/java/javase/downloads/index.html)
* [Maven 3.3.3](https://maven.apache.org/download.cgi) 
* [Npm 3.x.x](https://nodejs.org/en/)

*Recommended read:*

* [AOT Cookbook from angular doc](https://angular.io/docs/ts/latest/cookbook/aot-compiler.html)

### Optional manual modif to do in templates or generated code (temporary solution)

- In Application.java, replace "/" by "/aot/index.html".

### Run these commands to generate and run an Angular 2.4.0 web app:

By default this project reverses a [sample database schema](https://github.com/jaxio/celerio-angular-quickstart/blob/master/quickstart-conf/01-create.sql).
You may of course [reverse your own database schema](#how-to-use-your-own-database).

> **Note**: Downloading Maven dependencies + JavaScript dependencies may be long, so please be patient the first time you run these commands.

    git clone https://github.com/jaxio/celerio-angular-quickstart.git
    cd celerio-angular-quickstart/quickstart
    mvn -Pdb,metadata,gen generate-sources
    cd src/main/webapp
    npm install
    npm install @angular/compiler-cli @angular/platform-server --save
    npm install rollup rollup-plugin-node-resolve rollup-plugin-commonjs rollup-plugin-uglify --save-dev
    node copy-dist-files
    npm run build:aot    
    cd ../../..
    mvn package
    java -jar target/celerio-angular-quickstart.jar


Then open [http://localhost:8080/aot/index.html](http://localhost:8080/aot/index.html)

This is a work in progress... 
{'fraction_non_alphanumeric': 0.1288961038961039, 'fraction_numerical': 0.011688311688311689, 'mean_word_length': 3.7693498452012384, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 10, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 8, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2726110', 'n_tokens_mistral': 1024, 'n_tokens_neox': 966, 'n_words': 252}