Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

213
Views
Is there any way to manually produce an answer in a browser using JavaScript?

So I'm not 100% if the thing I'm asking for is called answer. If you open your browser's console, in any chromium-based browser it should look something like this: enter image description here

And in Firefox it looks something like this: enter image description here

It's the thing that the console writes to if you use something like document.getElementById.

Is there any way to write to said result/answer?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

The arrow to the left is the console telling you that some function returned some value.

If you paste this code to the console, and then run it by typing foo() and pressing enter:

function foo() {
   return "bar"
}

It will return the string "Bar", and the icon you mentioned will appear, indicating that some function simply returned a value and did nothing with it.

Edit: As others mentioned, if you use it with console.log("foo"), the arrow will appear with undefined because the function console.log() doesnt return anything, it explicity prints on the browser's console, but doesn't return any value. Any function that doesn't return a value, the console will return back that arrow with undefined.

Edit2: A full reference of what you can do with console is here: W3Schools Console Object

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!