мой компонент Vue не отображается в браузере, import customer from "./components/customer"
выдает ошибку
Я использую: - Phoenix 1.3 - Node v8.14.0
Ниже - мой код
assets / js / apps.js
import Vue from "vue";
import "axios";
import "./socket"; // To be used later
import customer from "./components/customer"; // this is the line that brings the error message
Vue.component("customer", customer);
new Vue({}).$mount("#takso-app");
lib / myApp / templates / pages / index.html.eex
<div id="takso-app" style="border:solid red 2px">
<customer></customer>
</div>
assets / js / components / customer.vue
<template>
<div>
<input type="text" class="form-control" id="address" placeholder = "address" v-model="address">
</div>
<div>
<textarea class="col-sm-12" style="background-color:#f4f7ff" rows="4" v-model="messages"></textarea>
</div>
</template>
<script>
import axios from "axios";
export default {
data: function() {
return {
address: "",
}
},
methods: {
submitBookingRequest: function() {
axios.post("/api/bookings",
{address: this.address})
.then(response => {
this.messages = response.data.msg;
}).catch(error => {
console.log(error);
});
}
}
}
</script>
Я ожидаю, что мои 2 ввода (адрес и сообщение) должны быть видны в index.html.ех