Skip to content
Open
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
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ By [bubbleflat.com](https://bubbleflat.com)

This package allow to display errors from laravel validation rules

! This package needs vue-resource to work !
# Requirements
[Vue Resource](https://github.com/pagekit/vue-resource) or [Axios](https://github.com/axios/axios)

# Installation

Expand Down Expand Up @@ -56,12 +57,18 @@ export default {
}
},

methods(){
methods : {
// Error are displayed if Laravel backend return 422 Http code with name as error
this.$http.post('/submit', {name: this.name});
submit() {
// submit via vue resource
this.$http.post('/submit', {name: this.name});

// submit via axios
axios.post('/submit', {name: this.name});
}
}

}

</script>
```
```