Skip to content

Commit

Permalink
basic setup with vue-native-router
Browse files Browse the repository at this point in the history
  • Loading branch information
gauravprwl14 committed Apr 17, 2018
1 parent db51a1e commit 78dcc5b
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 15 deletions.
23 changes: 8 additions & 15 deletions App.vue
@@ -1,17 +1,10 @@
<template>
<view class="container">
<text class="text-color-primary">My Vue Native App</text>
</view>
<setup></setup>
</template>

<style>
.container {
background-color: white;
align-items: center;
justify-content: center;
flex: 1;
}
.text-color-primary {
color: blue;
}
</style>

<script>
import Setup from "./src/boot/setup.vue";
export default {
components: { Setup }
};
</script>
20 changes: 20 additions & 0 deletions src/App.vue
@@ -0,0 +1,20 @@
<template>
<app-navigation></app-navigation>
</template>


<script>
import { StackNavigator } from "vue-native-router";
import Home from "./screens/home/index";
const AppNavigation = StackNavigator(
{
Home: { screen: Home }
},
{
initialRouteName: "Home"
}
);
export default {
components: { AppNavigation }
};
</script>
13 changes: 13 additions & 0 deletions src/boot/setup.vue
@@ -0,0 +1,13 @@
<template>
<app></app>
</template>


<script>
import { StackNavigator } from "vue-native-router";
import App from "../App.vue";
export default {
components: { App }
};
</script>
17 changes: 17 additions & 0 deletions src/screens/home/index.vue
@@ -0,0 +1,17 @@
<template>
<view class="container">
<text class="text-color-primary">My Vue Native App</text>
</view>
</template>

<style>
.container {
background-color: white;
align-items: center;
justify-content: center;
flex: 1;
}
.text-color-primary {
color: blue;
}
</style>

0 comments on commit 78dcc5b

Please sign in to comment.