简体   繁体   中英

How to debug javascript in Eclipse served by a Django Server

Let me 1st explain my setup. I am trying to build a website using Django as backend framework and with Twitter bootstrap as frontend framework (using the django frontend )

My env is CentOS 5.9 with Eclipse Kepler with Pydev, JSDT, WDT plugins (Python 2.7, Django 1.4+).

I am able to debug Django Python files (views.py) using --noreload (argument to manage.py) using the pydev perspective.

But how do I debug the frontend Javascript from Eclipse (I know I can use Chrome/Firefox tools, but I would like to debug and use JS autocomplete feature of Eclipse ) that is served from a Django server? To make things simple, I am running the Django manage.py from a terminal (unless someone can tell me how to debug Django and JS at same time from Eclipse?)

I know I can debug static pages using chrome dev tool with Eclipse , but I am looking for way to debug pages (JS, CSS) served by Django.

Thanks for the help :) Let me know if you think there is a better way to debug JS.

  1. Start a server on localhost
  2. open a browser and navigate to your local server.
  3. Use the built-in debugging capabilities of your browser.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM