<commit_before># Wisdom-TypeScript

[TypeScript](http://www.typescriptlang.org/)  lets you write JavaScript the way you really want to. TypeScript is a 
typed superset of JavaScript that compiles to plain JavaScript. Any browser. Any host. Any OS. Open Source.

Wisdom-TypeScript integrates TypeScript compilation into Wisdom. So, TypeScript files (`.ts` files) automatically 
compiled to JavaScript at build time.

It supports the Wisdom Watch Mode, so any change to a `.ts` file immediately triggers the compilation and updates the
output file.

## Usage

Add the following plugin to you `pom.xml` file:

````
<plugin>
    <groupId>org.wisdom-framework</groupId>
    <artifactId>wisdom-typescript-maven-plugin</artifactId>
    <version>${project.version}</version>
    <executions>
        <execution>
            <id>compile-typescript-files</id>
            <phase>compile</phase>
            <goals>
                <goal>compile-typescript</goal>
            </goals>
        </execution>
    </executions>
</plugin>
````

By default, TypeScript 1.0.1 is used, but you can set the version to use as follows:

````
<plugin>
    <groupId>org.wisdom-framework</groupId>
    <artifactId>wisdom-myth-maven-plugin</artifactId>
    <version>${project.version}</version>
    <executions>
            <execution>
                <id>compile-myth-files</id>
                <phase>compile</phase>
                <goals>
                    <goal>compile-myth</goal>
                </goals>
            </execution>
        </executions>
    <configuration>
        <version>1.0.1</version>
    </configuration>
</plugin>
````

## Examples

The  TypeScript files can be either in `src/main/resources/assets` (internal resources,
packaged within the application), or in `src/main/assets` (external resources, only packaged within the distribution).

For example, the file `src/main/resources/assets/Animal.ts` with the following content:

````
class Animal {
    constructor(public name: string) { }<commit_msg>Remove the last reference to myth in the README file<commit_after># Wisdom-TypeScript

[TypeScript](http://www.typescriptlang.org/)  lets you write JavaScript the way you really want to. TypeScript is a 
typed superset of JavaScript that compiles to plain JavaScript. Any browser. Any host. Any OS. Open Source.

Wisdom-TypeScript integrates TypeScript compilation into Wisdom. So, TypeScript files (`.ts` files) automatically 
compiled to JavaScript at build time.

It supports the Wisdom Watch Mode, so any change to a `.ts` file immediately triggers the compilation and updates the
output file.

## Usage

Add the following plugin to you `pom.xml` file:

````
<plugin>
    <groupId>org.wisdom-framework</groupId>
    <artifactId>wisdom-typescript-maven-plugin</artifactId>
    <version>${project.version}</version>
    <executions>
        <execution>
            <id>compile-typescript-files</id>
            <phase>compile</phase>
            <goals>
                <goal>compile-typescript</goal>
            </goals>
        </execution>
    </executions>
</plugin>
````

By default, TypeScript 1.0.1 is used, but you can set the version to use as follows:

````
<plugin>
    <groupId>org.wisdom-framework</groupId>
    <artifactId>wisdom-typescript-maven-plugin</artifactId>
    <version>${project.version}</version>
    <executions>
            <execution>
                <id>compile-typescript-files</id>
                <phase>compile</phase>
                <goals>
                    <goal>compile-typescript</goal>
                </goals>
            </execution>
        </executions>
    <configuration>
        <version>1.0.1</version>
    </configuration>
</plugin>
````

## Examples

The  TypeScript files can be either in `src/main/resources/assets` (internal resources,
packaged within the application), or in `src/main/assets` (external resources, only packaged within the distribution).

For example, the file `src/main/resources/assets/Animal.ts` with the following content:

````
class Animal {
    constructor(public name: string) { }
{'fraction_non_alphanumeric': 0.11594202898550725, 'fraction_numerical': 0.0029476787030213707, 'mean_word_length': 2.885496183206107, 'pattern_counts': {'":': 0, '<': 91, '<?xml version=': 0, '>': 91, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3449670', 'n_tokens_mistral': 1213, 'n_tokens_neox': 1130, 'n_words': 345}