question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Hello,

I’m trying to setup this package with vuejs. However I’m having issues displaying the errors.

My form data is contained inside the page field.

const form = new Form(this.page);
form.post(route('api.page.page.store'));

console.log(form.errors.all());

This returns {} image

However, in my network tab I do see the errors: image

When using the “manual” way, I can access the errors like so:

axios.post(route('api.page.page.store'), this.page)
    .then(response => {
        console.log(response);
    })
    .catch(response => {
        console.log(response.response.data);
    })

Am I missing something?

Thanks!

Edit: this is on laravel 5.5 and 2.0.1 of this package.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
mathieutucommented, Sep 13, 2017

@nWidart I’m not an expert but I think so! The form.post return a promise. So you have to .then or .catch after your post.

When you console.log, the request is not finished yet, so there isn’t any error, it’s normal. 🙂

0reactions
nWidartcommented, Sep 13, 2017

Indeed, thanks @sebastiandedeyne and @mathieutu for the hands-on help!

Here is the updated component, in wip, but at least displays some errors. 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

empty? (ActiveModel::Errors) - APIdock
empty?() public. Returns true if no errors are found, false otherwise. If the error message is a string it can be empty. person.errors.full_messages ......
Read more >
Unity 2019.2.* - Invisible/empty errors after trying to build
This issue has been solved with a response from the Unity team! This is their solution: Please try the following steps to fix...
Read more >
Bug - Empty error in console - Unity Forum
Hi guys, I recently installed Unity Linux 2017.3.0f1 and when I added a new C# script I get an empty error in the...
Read more >
I'm getting empty errors Unity 2019.2.14f1 Windows 10
Go to C:\Program Files\Unity\Hub\Editor\2019.2.14f1\Editor\Data\Tools\RoslynScripts folder Open the batch file in notepad and paste the ...
Read more >
Recurring Empty JS Errors - Browser - New Relic Explorers Hub
Over the last few months we are seeing an increase of empty/unnamed JavaScript errors which have no additional data in the detail view—as...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found