Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .expo/packager-info.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"expoServerPort": 19000,
"packagerPort": 19001,
"packagerPid": 6116,
"devToolsPort": 19002,
"expoServerNgrokUrl": "https://vc-2j2.anonymous.massa.exp.direct",
"packagerNgrokUrl": "https://packager.vc-2j2.anonymous.massa.exp.direct",
"ngrokPid": 9708
}
9 changes: 9 additions & 0 deletions .expo/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"hostType": "tunnel",
"lanType": "ip",
"dev": true,
"strict": false,
"minify": false,
"urlType": "exp",
"urlRandomness": "vc-2j2"
}
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ Change Directory To Massa
$ npm install
$ npm start
```
If Not Worked
```
$ expo start
```
## Screenshots
![ss](https://user-images.githubusercontent.com/17242746/47492102-db776200-d869-11e8-9a06-d2a48ffdcb3d.png)

Expand Down
3 changes: 3 additions & 0 deletions app.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
},
"ios": {
"supportsTablet": true
},
"android": {
"package": "com.test.testa"
}
}
}
39 changes: 37 additions & 2 deletions js/App.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
/* @flow */

import React from 'react';
import { Constants, ScreenOrientation } from 'expo';

import { Constants, ScreenOrientation , Permissions, Notifications} from 'expo';
ScreenOrientation.allow(ScreenOrientation.Orientation.ALL);

import {
Expand All @@ -20,6 +19,7 @@ import Banner from './Banner';
import SimpleStack from './SimpleStack';
import SimpleTabs from './SimpleTabs';
import TabAnimations from './TabAnimations';

const ExampleRoutes = {
SimpleStack: {
name: 'Massa Login',
Expand All @@ -34,12 +34,47 @@ const ExampleRoutes = {
description: 'To see invited friends and their download progress as well as chat with them',
screen: SimpleTabs,
}};


class MainScreen extends React.Component<*> {
constructor(props) {
super(props);

}
componentDidMount = () => {
this.getGCMToken();
}
getGCMToken = async() => {
const { status: existingStatus } = await Permissions.getAsync(
Permissions.NOTIFICATIONS
);
let finalStatus = existingStatus;

// only ask if permissions have not already been determined, because
// iOS won't necessarily prompt the user a second time.
if (existingStatus !== "granted") {
// Android remote notification permissions are granted during the app
// install, so this will only ask on iOS
const { status } = await Permissions.askAsync(Permissions.NOTIFICATIONS);
finalStatus = status;
}

// Stop here if the user did not grant permissions
if (finalStatus !== "granted") {
return;
}

// Get the token that uniquely identifies this device
let token = await Notifications.getExpoPushTokenAsync();

}
render() {
const { navigation } = this.props;

return (

<View style={{ flex: 1 }}>
<StatusBar hidden />
<ScrollView style={{ flex: 1 }}>
<Banner />
{Object.keys(ExampleRoutes).map((routeName: string) => (
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "0.1.0",
"private": true,
"main": "./node_modules/react-native-scripts/build/bin/crna-entry.js",

"scripts": {
"postinstall": "rm -rf node_modules/react-navigation/{node_modules,examples}",
"start": "react-native-scripts start",
Expand All @@ -14,7 +15,7 @@
"dependencies": {
"expo": "^26.0.0",
"react": "16.0.0",
"react-native": "^0.51.0",
"react-native": "^0.54.2",
"react-navigation": "^1.0.0-beta.23"
},
"devDependencies": {
Expand Down