<commit_before># react-native-layout

## Semantic JSX layout components for react-native

This project contains [react-native](https://facebook.github.io/react-native/)
layout components which brings more semantic to your JSX code.

It contains a "little bit more complex" [BorderLayout](/lib/BorderLayout.js),
as well as really simple layout modules like
[Center](/lib/Center.js), [Fill](/lib/Fill.js),
[Header](/lib/Header.js), [Footer](/lib/Footer.js),
and it also renames a view group as [LinearLayout](/lib/LinearLayout.js).

API, documentation and unit tests are WIP. Ideas, discussions and contributions
are welcome:
[Open an issue](https://github.com/jerolimov/react-native-layout/issues/new)

If your brave install the alpha version (0.0.x):

    npm install react-native-layout --save

You can expect a beta version (0.1.0) soon.

## Why?

Developing apps with [react-native](https://facebook.github.io/react-native/)
is great. But sometimes the JSX markup loses its simplicity with a growing
number of components and view elements.
Especially when you extracts and imports the
[stylesheets](https://facebook.github.io/react-native/docs/stylesheet.html)
from an external file.

## Examples

An example project is coming soon. Currently please checkout the `examples`
folder and the following inline codes.

<img width="200" alt="Screenshot of BorderLayoutExample1" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample1.png"><br/>
[BorderLayoutExample1.js](/examples/BorderLayoutExample1.js)

<img width="200" alt="Screenshot of BorderLayoutExample2" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample2.png"><br/>
[BorderLayoutExample2.js](/examples/BorderLayoutExample2.js)

<img width="200" alt="Screenshot of BorderLayoutExample3" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample3.png"><br/>
[BorderLayoutExample3.js](/examples/BorderLayoutExample3.js)

### Center Content

Instead of:

```jsx
<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
    <Text>Center Content</Text>
</View>
```

Write:

```jsx
<Center>
    <Text>Center Content</Text>
</Center>
```

### BorderLayout

Instead of:

```jsx
<Layout style={{ flex: 1 }}>
    <View><Text>Header</Text></View>
    <View style={{ flex: 1 }}><Text>Content</Text></View>
    <View><TextFooter</Text></View>
</Layout>
```

You could write:

```jsx
<Layout style={{ flex: 1 }}>
    <Top><Text>Header</Text></Top>
    <Bottom><TextFooter</Text></Bottom>
    <View style={{ flex: 1 }}><Text>Content</Text></View>
</Layout>
```<commit_msg>Update doc<commit_after># react-native-layout

## Semantic JSX layout components for react-native

This project contains [react-native](https://facebook.github.io/react-native/)
layout components which brings more semantic to your JSX code.

It contains a "little bit more complex" [BorderLayout](/lib/BorderLayout.js),
as well as really simple layout modules like
[Center](/lib/Center.js), [Fill](/lib/Fill.js),
[Header](/lib/Header.js), [Footer](/lib/Footer.js),
and it also renames a view group as [LinearLayout](/lib/LinearLayout.js).

API, documentation and unit tests are WIP. Ideas, discussions and contributions
are welcome:
[Open an issue](https://github.com/jerolimov/react-native-layout/issues/new)

If your brave install the alpha version (0.0.x):

    npm install react-native-layout --save

You can expect a beta version (0.1.0) soon.

## Why?

Developing apps with [react-native](https://facebook.github.io/react-native/)
is great. But sometimes the JSX markup loses its simplicity with a growing
number of components and view elements.
Especially when you extracts and imports the
[stylesheets](https://facebook.github.io/react-native/docs/stylesheet.html)
from an external file.

## Examples

An example project is coming soon. Currently please checkout the `examples`
folder and the following inline codes.

<img width="200" alt="Screenshot of BorderLayoutExample1" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample1.png"><br/>
[BorderLayoutExample1.js](/examples/BorderLayoutExample1.js)

<img width="200" alt="Screenshot of BorderLayoutExample2" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample2.png"><br/>
[BorderLayoutExample2.js](/examples/BorderLayoutExample2.js)

<img width="200" alt="Screenshot of BorderLayoutExample3" src="https://raw.githubusercontent.com/jerolimov/react-native-layout/master/screenshots/BorderLayoutExample3.png"><br/>
[BorderLayoutExample3.js](/examples/BorderLayoutExample3.js)

### Center Content

Instead of:

```jsx
<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
    <Text>Center Content</Text>
</View>
```

Write:

```jsx
<Center>
    <Text>Center Content</Text>
</Center>
```

### BorderLayout

Instead of:

```jsx
<View style={{ flex: 1 }}>
    <View><Text>Header</Text></View>
    <View style={{ flex: 1 }}><Text>Content</Text></View>
    <View><Text>Footer</Text></View>
</View>
```

You could write:

```jsx
<Fill>
    <Top><Text>Header</Text></Top>
    <Bottom><TextFooter</Text></Bottom>
    <View><Text>Content</Text></View>
</Fill>
```
{'fraction_non_alphanumeric': 0.15123688155922038, 'fraction_numerical': 0.011244377811094454, 'mean_word_length': 5.278823529411765, 'pattern_counts': {'":': 0, '<': 87, '<?xml version=': 0, '>': 84, 'https://': 14, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2573724', 'n_tokens_mistral': 1739, 'n_tokens_neox': 1652, 'n_words': 426}