Skip to content

Commit

Permalink
Batman! (this commit has no parents)
Browse files Browse the repository at this point in the history
  • Loading branch information
iboldurev committed Aug 4, 2019
0 parents commit 0922492
Show file tree
Hide file tree
Showing 64 changed files with 2,790 additions and 0 deletions.
62 changes: 62 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Built application files
template/android/*/build/

# Crashlytics configuations
template/android/com_crashlytics_export_strings.xml

# Local configuration file (sdk path, etc)
template/android/local.properties

# Gradle generated files
template/android/.gradle/

# Signing files
template/android/.signing/

# User-specific configurations
template/android/.idea/gradle.xml
template/android/.idea/libraries/
template/android/.idea/workspace.xml
template/android/.idea/tasks.xml
template/android/.idea/.name
template/android/.idea/compiler.xml
template/android/.idea/copyright/profiles_settings.xml
template/android/.idea/encodings.xml
template/android/.idea/misc.xml
template/android/.idea/modules.xml
template/android/.idea/scopes/scope_settings.xml
template/android/.idea/vcs.xml
template/android/*.iml

# Xcode
*.pbxuser
*.mode1v3
*.mode2v3
*.perspectivev3
*.xcuserstate
template/ios/Pods
template/ios/build
*project.xcworkspace*
*xcuserdata*

# OS-specific files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

# Android
template/android/build
template/android/.settings

.idea
yarn.lock
.github
.vscode
.nyc_output
*.coverage.json
.circleci
.eslintignore
65 changes: 65 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Built application files
template/android/*/build/

# Crashlytics configuations
template/android/com_crashlytics_export_strings.xml

# Local configuration file (sdk path, etc)
template/android/local.properties

# Gradle generated files
template/android/.gradle/

# Signing files
template/android/.signing/

# User-specific configurations
template/android/.idea/gradle.xml
template/android/.idea/libraries/
template/android/.idea/workspace.xml
template/android/.idea/tasks.xml
template/android/.idea/.name
template/android/.idea/compiler.xml
template/android/.idea/copyright/profiles_settings.xml
template/android/.idea/encodings.xml
template/android/.idea/misc.xml
template/android/.idea/modules.xml
template/android/.idea/scopes/scope_settings.xml
template/android/.idea/vcs.xml
template/android/*.iml

# Xcode
*.pbxuser
*.mode1v3
*.mode2v3
*.perspectivev3
*.xcuserstate
template/ios/Pods
template/ios/build
*project.xcworkspace*
*xcuserdata*

# OS-specific files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

# Android
template/android/build
template/android/.settings

# Node
template/node_modules

.idea
yarn.lock
.github
.vscode
.nyc_output
*.coverage.json
.circleci
.eslintignore
7 changes: 7 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Contributing

Contributing to this project should be as easy and transparent as possible.

## License

By contributing, you agree that your contributions will be licensed under the [MIT License](LICENSE).
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2019 Ivan Boldyrev

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# :flexed-biceps: React Native Airbnb Template

> Clean and minimalist React Native template for a quick start.
## :star: Features

- Elegant usage directly within the [React Native CLI](https://github.com/react-native-community/cli)
- Consistent with the default React Native template
- Minimal additional dependencies

## :arrow_forward: Usage

```sh
react-native init MyApp --template airbnb
```

## :computer: Contributing

Contributions are very welcome. Please check out the [contributing document](CONTRIBUTING.md).

## :bookmark: License

This project is [MIT](LICENSE) licensed.
5 changes: 5 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "react-native-template-airbnb",
"version": "0.0.1",
"description": "React Native Airbnb - Template",
"keywords": [
"react",
"react-native",
"cli",
"template",
"airbnb"
],
"main": "template.config.js",
"author": "Ivan Boldyrev <iboldurev@gmail.com>",
"license": "MIT"
}
4 changes: 4 additions & 0 deletions template.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module.exports = {
placeholderName: 'HelloWorld',
templateDir: './template',
}
115 changes: 115 additions & 0 deletions template/App.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
/**
* Sample React Native App
* https://github.com/facebook/react-native
*
* @format
* @flow
*/

import React, { Fragment } from 'react'
import {
SafeAreaView,
StyleSheet,
ScrollView,
View,
Text,
StatusBar,
} from 'react-native'

import {
Header,
LearnMoreLinks,
Colors,
DebugInstructions,
ReloadInstructions,
} from 'react-native/Libraries/NewAppScreen'

const App = () => {
return (
<Fragment>
<StatusBar barStyle="dark-content" />
<SafeAreaView>
<ScrollView
contentInsetAdjustmentBehavior="automatic"
style={styles.scrollView}
>
<Text>Demo Airbnb</Text>
{global.HermesInternal == null ? null : (
<View style={styles.engine}>
<Text style={styles.footer}>Engine: Hermes</Text>
</View>
)}
<View style={styles.body}>
<View style={styles.sectionContainer}>
<Text style={styles.sectionTitle}>Step One</Text>
<Text style={styles.sectionDescription}>
Edit <Text style={styles.highlight}>App.js</Text> to change this
screen and then come back to see your edits.
</Text>
</View>
<View style={styles.sectionContainer}>
<Text style={styles.sectionTitle}>See Your Changes</Text>
<Text style={styles.sectionDescription}>
<ReloadInstructions />
</Text>
</View>
<View style={styles.sectionContainer}>
<Text style={styles.sectionTitle}>Debug</Text>
<Text style={styles.sectionDescription}>
<DebugInstructions />
</Text>
</View>
<View style={styles.sectionContainer}>
<Text style={styles.sectionTitle}>Learn More</Text>
<Text style={styles.sectionDescription}>
Read the docs to discover what to do next:
</Text>
</View>
<LearnMoreLinks />
</View>
</ScrollView>
</SafeAreaView>
</Fragment>
)
}

const styles = StyleSheet.create({
scrollView: {
backgroundColor: Colors.lighter,
},
engine: {
position: 'absolute',
right: 0,
},
body: {
backgroundColor: Colors.white,
},
sectionContainer: {
marginTop: 32,
paddingHorizontal: 24,
},
sectionTitle: {
fontSize: 24,
fontWeight: '600',
color: Colors.black,
},
sectionDescription: {
marginTop: 8,
fontSize: 18,
fontWeight: '400',
color: Colors.dark,
},
highlight: {
fontWeight: '700',
},
footer: {
color: Colors.dark,
fontSize: 12,
fontWeight: '600',
padding: 4,
paddingRight: 12,
textAlign: 'right',
},
})

export default App
14 changes: 14 additions & 0 deletions template/__tests__/App-test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/**
* @format
*/

import 'react-native';
import React from 'react';
import App from '../App';

// Note: test renderer must be required after react-native.
import renderer from 'react-test-renderer';

it('renders correctly', () => {
renderer.create(<App />);
});
6 changes: 6 additions & 0 deletions template/_buckconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@

[android]
target = Google Inc.:Google APIs:23

[maven_repositories]
central = https://repo1.maven.org/maven2
4 changes: 4 additions & 0 deletions template/_eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module.exports = {
root: true,
extends: '@react-native-community',
};
Loading

0 comments on commit 0922492

Please sign in to comment.