This commit is contained in:
jslightham
2020-02-27 11:39:24 -05:00
parent fca7d1e8db
commit 52d2d79548
11 changed files with 121 additions and 25 deletions

View File

@@ -0,0 +1,37 @@
<template>
<div class="login-box">
<h1 class="title">Login</h1>
<div class="field">
<label class="label">Name</label>
<div class="control">
<input class="input" type="text" placeholder="e.g Alex Smith">
</div>
</div>
<div class="field">
<label class="label">Email</label>
<div class="control">
<input class="input" type="email" placeholder="e.g. alexsmith@gmail.com">
</div>
</div>
</div>
</template>
<script>
export default {
data(){
return {
post:{}
}
},
methods: {
login(){
let uri = 'http://localhost:4000/posts/add';
this.axios.post(uri, this.post).then(() => {
this.$router.push({name: 'posts'});
});
}
}
}
</script>