<commit_before># JavaScript CST implementation

### CST

CST means Concrete Syntax Tree. Unline AST (which is Abstract Syntax Tree), CST containst the whole information
from the JavaScript source file: whitespace, punctuators, comments.

This `CST` implementation is designed to be `100%` compatible with JS `AST` (https://github.com/estree/estree).

Let's see an example:

```js
x = 0;
if (x) x++;
```

CST for this example:

![](https://raw.githubusercontent.com/mdevils/cst/master/docs/cst-example.png)

* Blue text — CST Tokens.
* White text in blue blocks — CST Nodes (thir structure is equal to AST).
* Blue lines — CST Structure.<commit_msg>Spelling<commit_after># JavaScript CST implementation

### CST

CST means Concrete Syntax Tree. Unlike AST (which is Abstract Syntax Tree), CST contains the whole information
from the JavaScript source file: whitespace, punctuators, comments.

This `CST` implementation is designed to be `100%` compatible with JS `AST` (https://github.com/estree/estree).

Let's see an example:

```js
x = 0;
if (x) x++;
```

CST for this example:

![](https://raw.githubusercontent.com/mdevils/cst/master/docs/cst-example.png)

* Blue text — CST Tokens.
* White text in blue blocks — CST Nodes (thir structure is equal to AST).
* Blue lines — CST Structure.
{'fraction_non_alphanumeric': 0.11627906976744186, 'fraction_numerical': 0.006201550387596899, 'mean_word_length': 4.493617021276596, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '4952086', 'n_tokens_mistral': 429, 'n_tokens_neox': 406, 'n_words': 163}