Vue Native
Build mobile apps using Vue Native
Install #
npm i material-bread
or
yarn add material-bread
Setup #
Install Vue Native
Follow the instructions on Vue Native'sInstallation guide to make sure you have everything installed. Vue Native can be set up with either Expo or React Native directly. Once you've initialized a project, move onto the next step.
Dependencies
Install and link both react-native-vector-icons and react-native-svg .
npm i react-native-svg react-native-vector-icons
react-native link react-native-svg
react-native link react-native-vector-icons
Register Components
Material Bread supports kebab-case components, we simply have to register them with Vue Native to use them. Edit
App.vue
as follows<template>
<app></app>
</template>
<script>
import Vue from "vue-native-core";
import { VueMaterialBread } from "material-bread";
import App from "./src/App.vue";
// registering all components to the global scope of the Vue
Vue.use(VueMaterialBread);
export default {
components: { App }
};
</script>
Next, create the
src/App.vue
file and start using ecomponents
<template>
<view :style="{marginTop: 80}">
<mb-fab />
</view>
</template>
Examples #
If you're confused, check out thes example repo with Material Bread set up