Why does a switching to the developer mode break my site?

  1. Magento2 after change Mode default to developer website add to cart and js and ajax call are not working from listing page and products details.

  2. From Developer mode cant change to default mode.

How to diagnose Magento 2 errors