You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
then locate the **Console** tab. (short cut for linux ctrl+shift+j)
4
4
5
5
Voila! You now have access to the [Chrome V8 Engine](https://www.cloudflare.com/en-gb/learning/serverless/glossary/what-is-chrome-v8/).
6
6
Just like the Node REPL, you can input JavaScript code into the Console tab and the V8 engine will execute it.
@@ -9,10 +9,16 @@ Let's try an example.
9
9
10
10
In the Chrome console,
11
11
invoke the function `alert` with an input string of `"Hello world!"`;
12
+
ans: done!
12
13
13
14
What effect does calling the `alert` function have?
15
+
ans: pops out a message with given strings inside alert arguments
14
16
15
17
Now try invoking the function `prompt` with a string input of `"What is your name?"` - store the return value of your call to `prompt` in an variable called `myName`.
18
+
ans: myname = prompt("What is your name?");
16
19
17
20
What effect does calling the `prompt` function have?
21
+
ans: pops out a message with input field and we can store the input value into a variable
0 commit comments