简体   繁体   中英

Chrome dev tools didn't stopped on added breakpoints, instead they stopped at different exceptions present in React Modules

Here I have added the breakpoints on line number 2, 3, 5, 6, 7:

else{
    console.log('In the patch>>>>>>>started<<<<<<');
    axios.put(patchUser, { name : name, dateofbirth : dob, hobbies : hobby })
    .then((res) => {
        console.log(res);
        console.log("<<<<<<<<<<<<<<<<<>>>>>>In the patch....>>>>>>>>");
        alert(res);
        window.location.reload(false);
    })
}

And, in the next code where the dev tools stopped for debugging on line no 4 (throw Error)

if (prefix === undefined) {
  // Extract the VM specific prefix used by each line.
  try {
    throw Error();
  } catch (x) {
    var match = x.stack.trim().match(/\n( *(at )?)/);
    prefix = match && match[1] || '';
  }
} // We use the prefix to ensure our stacks line up with native stack frames.


return '\n' + prefix + name;

} }

Thank you so much in advance for any support.

When you go into 'sources' in dev tools. To your far right you can select 'deactivate breakpoints' and 'pause on exceptions'. Plz see if you by accident pressed on any of these.

Not a dev tools pro, but remember I was struggling with the same at one time :)

Best, Rune

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM