-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Dabit
committed
Mar 21, 2018
0 parents
commit ab04e27
Showing
123 changed files
with
9,374 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"presets": ["react-native"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
[ignore] | ||
; We fork some components by platform | ||
.*/*[.]android.js | ||
|
||
; Ignore "BUCK" generated dirs | ||
<PROJECT_ROOT>/\.buckd/ | ||
|
||
; Ignore unexpected extra "@providesModule" | ||
.*/node_modules/.*/node_modules/fbjs/.* | ||
|
||
; Ignore duplicate module providers | ||
; For RN Apps installed via npm, "Libraries" folder is inside | ||
; "node_modules/react-native" but in the source repo it is in the root | ||
.*/Libraries/react-native/React.js | ||
|
||
; Ignore polyfills | ||
.*/Libraries/polyfills/.* | ||
|
||
; Ignore metro | ||
.*/node_modules/metro/.* | ||
|
||
[include] | ||
|
||
[libs] | ||
node_modules/react-native/Libraries/react-native/react-native-interface.js | ||
node_modules/react-native/flow/ | ||
node_modules/react-native/flow-github/ | ||
|
||
[options] | ||
emoji=true | ||
|
||
module.system=haste | ||
|
||
munge_underscores=true | ||
|
||
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub' | ||
|
||
module.file_ext=.js | ||
module.file_ext=.jsx | ||
module.file_ext=.json | ||
module.file_ext=.native.js | ||
|
||
suppress_type=$FlowIssue | ||
suppress_type=$FlowFixMe | ||
suppress_type=$FlowFixMeProps | ||
suppress_type=$FlowFixMeState | ||
|
||
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(<VERSION>\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) | ||
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(<VERSION>\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ | ||
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy | ||
suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError | ||
|
||
unsafe.enable_getters_and_setters=true | ||
|
||
[version] | ||
^0.61.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
*.pbxproj -text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# OSX | ||
# | ||
.DS_Store | ||
|
||
# AWS | ||
awsmobilejs | ||
aws-exports.js | ||
src/aws-exports.js | ||
|
||
# Xcode | ||
# | ||
build/ | ||
*.pbxuser | ||
!default.pbxuser | ||
*.mode1v3 | ||
!default.mode1v3 | ||
*.mode2v3 | ||
!default.mode2v3 | ||
*.perspectivev3 | ||
!default.perspectivev3 | ||
xcuserdata | ||
*.xccheckout | ||
*.moved-aside | ||
DerivedData | ||
*.hmap | ||
*.ipa | ||
*.xcuserstate | ||
project.xcworkspace | ||
|
||
# Android/IntelliJ | ||
# | ||
build/ | ||
.idea | ||
.gradle | ||
local.properties | ||
*.iml | ||
|
||
# node.js | ||
# | ||
node_modules/ | ||
npm-debug.log | ||
yarn-error.log | ||
|
||
# BUCK | ||
buck-out/ | ||
\.buckd/ | ||
*.keystore | ||
|
||
# fastlane | ||
# | ||
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the | ||
# screenshots whenever they are needed. | ||
# For more information about the recommended setup visit: | ||
# https://docs.fastlane.tools/best-practices/source-control/ | ||
|
||
*/fastlane/report.xml | ||
*/fastlane/Preview.html | ||
*/fastlane/screenshots | ||
|
||
#awsmobilejs | ||
aws-info.json | ||
project-info.json | ||
aws-exports.js | ||
awsmobilejs/.awsmobile/backend-build | ||
awsmobilejs/\#current-backend-info | ||
~awsmobilejs-*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
## Code of Conduct | ||
This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). | ||
For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact | ||
[email protected] with any additional questions or comments. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Contributing Guidelines | ||
|
||
Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, correction, or additional | ||
documentation, we greatly value feedback and contributions from our community. | ||
|
||
Please read through this document before submitting any issues or pull requests to ensure we have all the necessary | ||
information to effectively respond to your bug report or contribution. | ||
|
||
|
||
## Reporting Bugs/Feature Requests | ||
|
||
We welcome you to use the GitHub issue tracker to report bugs or suggest features. | ||
|
||
When filing an issue, please check [existing open](https://github.com/aws-samples/react-native-auth-starter/issues), or [recently closed](https://github.com/aws-samples/react-native-auth-starter/issues?utf8=%E2%9C%93&q=is%3Aissue%20is%3Aclosed%20), issues to make sure somebody else hasn't already | ||
reported the issue. Please try to include as much information as you can. Details like these are incredibly useful: | ||
|
||
* A reproducible test case or series of steps | ||
* The version of our code being used | ||
* Any modifications you've made relevant to the bug | ||
* Anything unusual about your environment or deployment | ||
|
||
|
||
## Contributing via Pull Requests | ||
Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that: | ||
|
||
1. You are working against the latest source on the *master* branch. | ||
2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already. | ||
3. You open an issue to discuss any significant work - we would hate for your time to be wasted. | ||
|
||
To send us a pull request, please: | ||
|
||
1. Fork the repository. | ||
2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change. | ||
3. Ensure local tests pass. | ||
4. Commit to your fork using clear commit messages. | ||
5. Send us a pull request, answering any default questions in the pull request interface. | ||
6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation. | ||
|
||
GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and | ||
[creating a pull request](https://help.github.com/articles/creating-a-pull-request/). | ||
|
||
|
||
## Finding contributions to work on | ||
Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels ((enhancement/bug/duplicate/help wanted/invalid/question/wontfix), looking at any ['help wanted'](https://github.com/aws-samples/react-native-auth-starter/labels/help%20wanted) issues is a great place to start. | ||
|
||
|
||
## Code of Conduct | ||
This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). | ||
For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact | ||
[email protected] with any additional questions or comments. | ||
|
||
|
||
## Security issue notifications | ||
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue. | ||
|
||
|
||
## Licensing | ||
|
||
See the [LICENSE](https://github.com/aws-samples/react-native-auth-starter/blob/master/LICENSE) file for our project's licensing. We will ask you to confirm the licensing of your contribution. | ||
|
||
We may ask you to sign a [Contributor License Agreement (CLA)](http://en.wikipedia.org/wiki/Contributor_License_Agreement) for larger changes. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
Amazon Software License 1.0 | ||
|
||
This Amazon Software License ("License") governs your use, reproduction, and | ||
distribution of the accompanying software as specified below. | ||
|
||
1. Definitions | ||
|
||
"Licensor" means any person or entity that distributes its Work. | ||
|
||
"Software" means the original work of authorship made available under this | ||
License. | ||
|
||
"Work" means the Software and any additions to or derivative works of the | ||
Software that are made available under this License. | ||
|
||
The terms "reproduce," "reproduction," "derivative works," and | ||
"distribution" have the meaning as provided under U.S. copyright law; | ||
provided, however, that for the purposes of this License, derivative works | ||
shall not include works that remain separable from, or merely link (or bind | ||
by name) to the interfaces of, the Work. | ||
|
||
Works, including the Software, are "made available" under this License by | ||
including in or with the Work either (a) a copyright notice referencing the | ||
applicability of this License to the Work, or (b) a copy of this License. | ||
|
||
2. License Grants | ||
|
||
2.1 Copyright Grant. Subject to the terms and conditions of this License, | ||
each Licensor grants to you a perpetual, worldwide, non-exclusive, | ||
royalty-free, copyright license to reproduce, prepare derivative works of, | ||
publicly display, publicly perform, sublicense and distribute its Work and | ||
any resulting derivative works in any form. | ||
|
||
2.2 Patent Grant. Subject to the terms and conditions of this License, each | ||
Licensor grants to you a perpetual, worldwide, non-exclusive, royalty-free | ||
patent license to make, have made, use, sell, offer for sale, import, and | ||
otherwise transfer its Work, in whole or in part. The foregoing license | ||
applies only to the patent claims licensable by Licensor that would be | ||
infringed by Licensor's Work (or portion thereof) individually and | ||
excluding any combinations with any other materials or technology. | ||
|
||
3. Limitations | ||
|
||
3.1 Redistribution. You may reproduce or distribute the Work only if | ||
(a) you do so under this License, (b) you include a complete copy of this | ||
License with your distribution, and (c) you retain without modification | ||
any copyright, patent, trademark, or attribution notices that are present | ||
in the Work. | ||
|
||
3.2 Derivative Works. You may specify that additional or different terms | ||
apply to the use, reproduction, and distribution of your derivative works | ||
of the Work ("Your Terms") only if (a) Your Terms provide that the use | ||
limitation in Section 3.3 applies to your derivative works, and (b) you | ||
identify the specific derivative works that are subject to Your Terms. | ||
Notwithstanding Your Terms, this License (including the redistribution | ||
requirements in Section 3.1) will continue to apply to the Work itself. | ||
|
||
3.3 Use Limitation. The Work and any derivative works thereof only may be | ||
used or intended for use with the web services, computing platforms or | ||
applications provided by Amazon.com, Inc. or its affiliates, including | ||
Amazon Web Services, Inc. | ||
|
||
3.4 Patent Claims. If you bring or threaten to bring a patent claim against | ||
any Licensor (including any claim, cross-claim or counterclaim in a | ||
lawsuit) to enforce any patents that you allege are infringed by any Work, | ||
then your rights under this License from such Licensor (including the | ||
grants in Sections 2.1 and 2.2) will terminate immediately. | ||
|
||
3.5 Trademarks. This License does not grant any rights to use any | ||
Licensor's or its affiliates' names, logos, or trademarks, except as | ||
necessary to reproduce the notices described in this License. | ||
|
||
3.6 Termination. If you violate any term of this License, then your rights | ||
under this License (including the grants in Sections 2.1 and 2.2) will | ||
terminate immediately. | ||
|
||
4. Disclaimer of Warranty. | ||
|
||
THE WORK IS PROVIDED "AS IS" WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, | ||
EITHER EXPRESS OR IMPLIED, INCLUDING WARRANTIES OR CONDITIONS OF | ||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE OR | ||
NON-INFRINGEMENT. YOU BEAR THE RISK OF UNDERTAKING ANY ACTIVITIES UNDER | ||
THIS LICENSE. SOME STATES' CONSUMER LAWS DO NOT ALLOW EXCLUSION OF AN | ||
IMPLIED WARRANTY, SO THIS DISCLAIMER MAY NOT APPLY TO YOU. | ||
|
||
5. Limitation of Liability. | ||
|
||
EXCEPT AS PROHIBITED BY APPLICABLE LAW, IN NO EVENT AND UNDER NO LEGAL | ||
THEORY, WHETHER IN TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE | ||
SHALL ANY LICENSOR BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY DIRECT, | ||
INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF OR | ||
RELATED TO THIS LICENSE, THE USE OR INABILITY TO USE THE WORK (INCLUDING | ||
BUT NOT LIMITED TO LOSS OF GOODWILL, BUSINESS INTERRUPTION, LOST PROFITS | ||
OR DATA, COMPUTER FAILURE OR MALFUNCTION, OR ANY OTHER COMM ERCIAL DAMAGES | ||
OR LOSSES), EVEN IF THE LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF | ||
SUCH DAMAGES. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
React Native Auth Starter with AWS Amplify | ||
Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
# React Native Auth Starter | ||
|
||
Easy authentication for your next React Native app. | ||
|
||
 | ||
|
||
### 🎧 Powered by [Amplify](https://github.com/aws/aws-amplify) | ||
|
||
## Features | ||
|
||
✅ Preconfigured, production tested authentication flow | ||
|
||
✅ 2 Factor Authentication Enabled | ||
|
||
✅ React Navigation | ||
|
||
✅ Redux | ||
|
||
✅ Amplify React Native | ||
|
||
✅ Opinionated yet configurable | ||
|
||
✅ Themeable | ||
|
||
✅ Cross-Platform | ||
|
||
|
||
## Roadmap | ||
|
||
⬜️ Social Logins / Federated Identities | ||
|
||
⬜️ Optional intro / onboarding flow | ||
|
||
|
||
## Getting Started | ||
|
||
1. Clone project | ||
|
||
``` | ||
git clone https://github.com/dabit3/react-native-auth-starter.git | ||
``` | ||
|
||
2. Change into react-native-auth-starter directory | ||
|
||
``` | ||
cd react-native-auth-starter | ||
``` | ||
|
||
3. Install dependencies | ||
|
||
``` | ||
yarn || npm install | ||
``` | ||
|
||
4. Configure AWS Amplify config in `index.js` by adding your own `aws-export.js` file in the `src` directory. If you do not already have this file, continue to step 5 | ||
|
||
---- | ||
|
||
5. Install [AWSMobile CLI](https://github.com/aws/awsmobile-cli) if not already installed and configured (for steps on how to configure AWSMobile CLI, see [this](https://www.youtube.com/watch?v=MpugaNKtw3k) two minute video) | ||
|
||
``` | ||
npm i -g awsmobile-cli | ||
awsmobile configure | ||
``` | ||
|
||
6. Create a new AWS Mobile Hub Project using the AWSMobile CLI | ||
|
||
``` | ||
awsmobile init | ||
``` | ||
|
||
7. Enable User Sign In | ||
|
||
``` | ||
awsmobile user-signin enable | ||
awsmobile push | ||
``` |
Oops, something went wrong.