Range attribute only showing { Start: [object], End: [object] } in JS implementation #2180
Answered
by
P0lip
JosephSNewman
asked this question in
Q&A
-
I wrote a rule in JS and lint through JS code, but when I call the file in the cmd line the range attributes seem to be empty. did I miss something in the rule? Why does this happen? Thank you!
|
Beta Was this translation helpful? Give feedback.
Answered by
P0lip
Jun 9, 2022
Replies: 1 comment 4 replies
-
If you use |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
JosephSNewman
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you use
console.log
to print out the result, you need to stringify the result prior to that, asconsole.log
doesn't print objects that are deeply nested within other objects.In other words, the update code could look as follows
console.log(JSON.stringify(results, null, 2));