Console - Reading Assignment

Good answers @Matoshi!

Yes, we can change the contents of an HTML page there :+1:
In the actual console, we can do this by writing JavaScript code that accesses and manipulates the page’s Document Object Model (DOM).

1 Like
1.What is the console used for?

To provide a space to write, manage, and monitor JavaScript in real-time.

2.How do you open the Console in Google Chrome?

Ctrl + Shift + J
or
go to the menu at the top-right of the browser window (three vertical dots) and select ā€œMore Toolsā€ >> ā€œDeveloper Toolsā€ >> Select ā€œConsoleā€ on the upper bar.

3.What does console.log function do?

Output any kind of variables defined before printing them in the console

4.How can you change the contents of an HTML page through the console?

Through the elements tab and change the inputs on the Document Object Model (DOM) directly or use the console to manipulates the DOM’s content by writing JavaScript code.

1 Like
  1. Console is used for monitoring network activity, debug and inspect DOM and allows us to write, manage and modify Javascript on demand.

  2. Keyword shortcut CTRL+SHIFT+J

  3. Displays the output in the Console window instead of on the webpage itself.

  4. You can load an HTML file into a dynamic window in the console to test in real time the interactiv content of the webpage.

1 Like
  1. What is the console used for?
    The console is a way to test, debug, monitor and manage javascripts on a web browser in real time.
  2. How do you open the Console in Google Chrome?
    CTRL + SHIFT + J for Linux and Windows, or CMD + OPTION + K for MacOS
  3. What does console.log function do?
    It is a way for the console to execute the code in the console.
  4. How can you change the contents of an HTML page through the console?
    The contents of an HTML page can be altered by interacting with the documents elements, however, the changes made are not permeant.
1 Like
  1. The console is used to write, manage and monitor JavaScript on demand.
  2. To open the Console in Google Chrome, go to the menu in the top right and navigate to more tools > developer tools.
  3. The console.log returns the output directly in the console.
  4. To change the contents of an HTML page through the Console, navigate to ā€˜Elements’ and double-click to select the element you want to change.
1 Like

1. What is the console used for?
The Console can be used to log information as part of the JavaScript development process, as well as allow you to interact with a web page by carrying out JavaScript expressions within the page’s context. Essentially, the Console provides you with the ability to write, manage, and monitor JavaScript on demand.

2. How do you open the Console in Google Chrome?

To open the JavaScript Console in Chrome, you can navigate to the menu at the top-right of your browser window signified by three vertical dots in a row. From there, you can select More Tools then Developer Tools.

Chrome Developer Tools Menu Item

This will open a panel where you can click on Console along the top menu bar to bring up the JavaScript Console.

3. What does console.log function do?
Testing and coding in real time javascript console.

4. How can you change the contents of an HTML page through the console?
Double click a selected element and make changes within the element panel

1 Like
  1. What is the console used for?
    The console can be used to log information as part of the JavaScript development process and specifically the ability to write, manage and monitor JavaScript on demand.

  2. How do you open the Console in Google Chrome?
    Command+Option+J

  3. What does console.log function do?
    The function takes the console information and putting it into the JavaScript function.

  4. How can you change the contents of an HTML page through the console?
    Through using the document element.

1 Like

The Javascript console provides you with the ability to write, manage, and monitor JavaScript on demand.It allow you to interact with a web page by carrying out JavaScript expressions within the page’s context.

There are few options (using Brave that is the same as Chrome):

  • Press F12
  • Press ctrl+shift+I
  • Click on the ā€œ3 linesā€ top right of the browser, then go ā€œMore toolsā€ and select ā€œDeveloper Toolsā€

The console. log is a function in JavaScript used to print any kind of variables defined before in it or to just print any message that needs to be displayed to the user.

You have to click on elements tab/page of the Console, there you can temporarily edit anything about the webpage you are visualizing. If you refresh the page, the page will be back as was at the start.

1 Like
  1. The Console gives me the ability to write, manage, and monitor JavaScript from the browser.
  2. CTRL + Shift + I. Or Menu -> More Tools -> Developer Tools.
  3. It allows for commands to be output directly in the console, rather than expressed in the browser.
  4. You do this by using functions that will edit HTML elements, attributes and variables. This is possible because Javascript can read and write the Document Object Model in the browser.
1 Like
  • What is the console used for?
    Console allows you to write and manage Javascript and test its interaction within a webpage context.

  • How do you open the Console in Google Chrome?
    Navigate to the developer tools menu option. This will open a window with a few tabs and console will be found therein.

  • What does console.log function do?
    This function allows you to test commands and contain the result or output within the terminal type space.

  • How can you change the contents of an HTML page through the console?
    HTML elements can be modified by modifying the Document Object Model under the DOM panel using Javascript. Once the page is reloaded the changes are lost so the test code needs to be actively saved.

1 Like

How do you open the Console in Google Chrome?

  • Open your Google Chrome browser

  • Tap on the three vertical dotted lines at the top right corner of the browser (beneath the Windows close button)

  • Tap on ā€œSettingsā€

  • Then scroll down to the bottom and tap on ā€œAdvancedā€ to get to the other side of Chrome settings

  • Under privacy and security, scroll down to where you have content settings and click on it

1 Like

1.The console is used for working with JavaScript in an interface similar to a terminal shell.

  1. through the top right hand menu, go to more tools, then down to dev tools. the second tab is the console.

  2. the console.log function simply places text in the console log.

  3. once you.ve saved your html file you can open it in the browser you prefer and then open up the console and make changes

1 Like
  1. What is the console used for? To check and execute JS code
  2. How do you open the Console in Google Chrome? There are several ways. In Chrome Menu Ć  More tools Ć  Developer tools or F12. Standard for all browsers Ctrl+Shift+J
  3. What does console.log function do? The console will show the result without actually run the code
  4. How can you change the contents of an HTML page through the console? by using the instruction document.body.innerHTML
1 Like
  1. The console allows you to work with Javascript in the context of the webpage. The ability to write, manage and monitor Javascript within the browser.

  2. Menu > More Tools > Developer Tools.

  3. Allows you to log into the console in order to work with Javascript.

  4. Using the DOM feature.

1 Like

1 What is the console used for?

The console provides you the ability to write, manage, and monitor JavaScript on demand.

2 How do you open the Console in Google Chrome?

CONTROL+SHIFT+J

3 What does console.log function do?

It makes it easier to work in Javascript (avoid pop-ups). It logs info that result into ā€˜output’ (example: math calculations).

4 How can you change the contents of an HTML page through the console?

Just dubbel click on the element and edit.

1 Like
  1. Console is used for interaction with the JS in the browser.

  2. COMMAND+OPTION+J or CTRL+SHIFT+J then console panel.

  3. Logs information on the JavaScript console.

  4. In the chrome through element panel in html tree.

1 Like

Hi @Adrian_P!

Just a few additional observations to clarify certain points…

  • Yes…you can use the console to debug, and to write, manage and modify JavaScript :+1:

  • The other activities you mention are performed with some of the other web developer tools available in the browser (e.g.Chrome DevTools) — the console is just one of several of these tools (accessible by clicking on different tabs in the menu bar).

I think you are referring to the Elements tool. But you can do the same thing in the console by writing JavaScript code which accesses and manipulates the page’s Document Object Model (DOM).

2 Likes

Hi @AF90!

Just to clarify one point…

Yes, we can change the contents of an HTML page there :+1: But this is a different developer tool.
In the actual console, we can do this by writing JavaScript code that accesses and manipulates the page’s Document Object Model (DOM) .

2 Likes

Hi @Omar!

Just to clarify a couple of points…

More specifically, this function enables information to be displayed on the screen (literally logged to the console ). The information logged is whatever value is defined within the parentheses.

Yes, we can change the contents of an HTML page there :+1: But this is a different developer tool.
In the actual console, we can do this by writing JavaScript code that accesses and manipulates the page’s Document Object Model (DOM) .

2 Likes

Hi @WeRise!

Just a couple of observations…

Is it CMD + OPTION + J or K with a Mac OS?

… and the console.log() function then displays the value defined within its parentheses on the screen (literally logged to the console).

1 Like