data:text/html, <html contenteditable="">
</html>
2. By typing below you can quickly run your html without running html file
data:text/html,<h1>
hay, I am html</h1>
3. By typing below in your browser console you can make page editable
document.body.contentEditable='true';4. In mordern browser if you define any element with some Id it create a JS global variable
document.designMode='on
<div id="IAmaDiv"></div>
console.log(IAMaDiv); // <div id="IAmaDiv"></div>
5. You can pass multiple statement inside if statement without using curly braces
if (confirm("wanna see two alerts?")) alert("first"), alert("second");
6. If you want to disable alert in a Html page ,you can type this in console
alert = console.log.bind(console);
7. If you wanna print an array in table form.You can use below in Chrome
var author = [{name: 'ashish', age: 24}, {name: 'Nautiyal', age: 23}]; console.table(author);
8. console.log($0); returns the currently selected element in Chrome
9. monitorEvents(window,'click'); can monitor all the click event on page in google chrome
10. debug(debugThisFunction); will kick on debugger whenever control will execute debugThisFunction
11. Typing keys(window); in console will return an Array of global objects
12 . history.pushState({}, '', "changedurl"); by using this you can change your url bar in browser to something else
0 comments:
Post a Comment
...