# Tracing through code?

**URL:** <https://forum.wixstudio.com/t/tracing-through-code/11502>\
**Category:** Ask the community\
**Tags:** code, question\
**Created:** [August 23, 2018, 7:52pm UTC](https://forum.wixstudio.com/t/tracing-through-code/11502 "2018-08-23T19:52:59Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![abergquist](https://avatars.discourse-cdn.com/v4/letter/a/c6cbf5/32.png) [@abergquist](https://forum.wixstudio.com/u/abergquist)\
**Post date:** [August 23, 2018, 7:52pm UTC](https://forum.wixstudio.com/t/tracing-through-code/11502/1 "2018-08-23T19:52:59Z")

</div>

Hi, all.

I’ve debugged JavaScript code before (in non-Wix contexts) by going to the Sources tab in Developer Tools, setting a breakpoint and running to that breakpoint.

In looking at the files in Sources, I conclude that Wix is written in React which is cool. Just curious, though: shouldn’t I be able to see any of my code (specifically, a backend .jsw) so that I can set a breakpoint therein?

---

<div class="post-metadata">

**Author:** ![abergquist](https://avatars.discourse-cdn.com/v4/letter/a/c6cbf5/32.png) [@abergquist](https://forum.wixstudio.com/u/abergquist)\
**Post date:** [August 24, 2018, 2:23am UTC](https://forum.wixstudio.com/t/tracing-through-code/11502/2 "2018-08-24T02:23:03Z")

</div>

Specifically, I’m calling a backend method from a web page and it’s apparently not going into that method; a console.log() before the method logs that fact as well as after the method but multiple console.log() calls within the method itself aren’t firing (not seeing anything in the console).

(I am correctly import-ing the method from the backend .jsw file [to confirm, I believe the “JS” part of .jsw stands for JavaScript; does the “W” stand for “web”?].)

---

<div class="post-metadata">

**Author:** ![abergquist](https://avatars.discourse-cdn.com/v4/letter/a/c6cbf5/32.png) [@abergquist](https://forum.wixstudio.com/u/abergquist)\
**Post date:** [August 24, 2018, 4:44am UTC](https://forum.wixstudio.com/t/tracing-through-code/11502/3 "2018-08-24T04:44:55Z")

</div>

OK, I believe that the reason that console.log() won’t work from the backend is that it’s a client-side, not a server-side, concept.

Assuming that’s the case, any recommendations for debugging backend code?

---

<div class="post-metadata">

**Author:** ![abergquist](https://avatars.discourse-cdn.com/v4/letter/a/c6cbf5/32.png) [@abergquist](https://forum.wixstudio.com/u/abergquist)\
**Post date:** [August 24, 2018, 5:13am UTC](https://forum.wixstudio.com/t/tracing-through-code/11502/4 "2018-08-24T05:13:51Z")

</div>

Just found out from [Velo: Testing and Troubleshooting Your Code | Help Center | Wix.com](https://support.wix.com/en/article/testing-and-debugging-code-with-wix-code) that you can console.log() from the backend when a Preview-ed website but not from a Publish-ed website.

---

<div class="post-metadata">

**Author:** ![jcampos](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/jcampos/32/10121_2.png) [@jcampos](https://forum.wixstudio.com/u/jcampos)\
**Post date:** [April 18, 2019, 9:32pm UTC](https://forum.wixstudio.com/t/tracing-through-code/11502/5 "2019-04-18T21:32:14Z")

</div>

That’s correct…Wix should implement a Trace option for the backend logs…
