As a theme or plugin developer, you definitely debug your code while working on it. If you're developing WordPress website then you can simplify the debugging process by using tools, describes in this article to enhance your quality of code and productivity.
Chrome Console
The Chrome Developer Tools (DevTools for short), are a set of web authoring and debugging tools built into Google Chrome. The DevTools provide web developers deep access into the internals of the browser and their web application. Use the DevTools to efficiently track down layout issues, set JavaScript breakpoints, and get insights for code optimization.
Firebug
Firebug integrates with Firefox to put a wealth of web development tools at your fingertips while you browse. You can edit, debug, and monitor CSS, HTML, and JavaScript live in any web page
Debug Bar
Debug Bar is a plugin which is available free of cost in the Wordpress plugin directory and adds a debug menu to the admin bar that shows query, cache, and other helpful debugging information.
Debugger
It is another plugin in the Wordpress extension directory that helps to manually log data or to capture logging on WordPress actions. You can capture load time, memory, backtrace, data dumps, URLs, and server IPs
Theme Check
Add this plugin in your Wordpress to test your theme for all the latest WordPress standards and practices. It is a great theme development tool. With it, you can run all the same automated testing tools on your theme that WordPress.org uses for theme submissions.