Javascript console.groupCollapsed() Method end group

Introduction

End a group by using the console.groupEnd() method:

Press F12 on your keyboard to view the message in the console view.

View in separate window

<!DOCTYPE html>
<html>
<body>
<script>

console.log("Hello world!");
console.groupCollapsed();
console.log("Hello again, this time inside a collapsed group!");
console.groupEnd();
console.log("and we are back.");

</script>/*w  w w . j  a  va2 s.c  o m*/

</body>
</html>



PreviousNext

Related