Cmd + O
Cmd + Opt + F
Windows: Ctrl + O, Ctrl + Shift + F
DevTools can pause on
demo
var originalSetItem = localStorage.setItem;
localStorage.setItem = function(){
debugger;
return originalSetItem.apply(this, arguments);
}
Break on
Pause on:
paul irish snippet collection
hard to understand snippets just from this screenshot
extension?
console.log("Post:", post);
Immutable DevTools
console.time("Loop");
for (var i=0; i<1000000; i++) { }
console.timeEnd("Loop")
React Developer Tools
function calculateHolidayCost(){var t=0;t+=getFlightCost(
);t+=getHotelCost();t+=getFoodCost();debugger;return t}fu
nction getHotelCost(){return parseFloat("GBP200")}functio
n getFlightCost(){return 300}function getFoodCost(){retur
n 200}function onButtonClick(){var t=document.getElementB
yId("value");t.innerHTML=calculateHolidayCost()}
uglifyjs all.js
-o all.min.js
--source-map all.min.map
--mangle --compress
function calculateHolidayCost(){var t=0;t+=getFlightCost(
);t+=getHotelCost();t+=getFoodCost();debugger;return t}fu
nction getHotelCost(){return parseFloat("GBP200")}functio
n getFlightCost(){return 300}function getFoodCost(){retur
n 200}function onButtonClick(){var t=document.getElementB
yId("value");t.innerHTML=calculateHolidayCost()}
//# sourceMappingURL=all.min.map
function calculateHolidayCost() {
var t = 0;
return t += getFlightCost(),
t += getHotelCost(),
t += getFoodCost()
}
<=> WebSockets <=>
Chrome Desktop
DevTools
(Chrome Debugger Protocol)
<=> WebSockets <=>
Chrome Desktop
Chrome on Android
Node
DevTools
(Chrome Debugger Protocol)
$ node-debug test.js
<=> WebSockets <=>
Chrome Desktop
DevTools
Sublime Text
WebStorm
IntelliJ IDEA
Visual Studio Code
(Chrome Debugger Protocol)
https://umaar.com/dev-tips/
@mattzeunert