From a3cdace8d2cea8caee000d1954c280b2816d5dbb Mon Sep 17 00:00:00 2001 From: Gustl22 Date: Sat, 19 Jan 2019 18:37:07 +0100 Subject: [PATCH] Web: doc for debugging (#632) --- docs/web.md | 22 ++++++++++++++++++++++ vtm-web/HOWTO-SuperDevMode.txt | 14 -------------- 2 files changed, 22 insertions(+), 14 deletions(-) delete mode 100644 vtm-web/HOWTO-SuperDevMode.txt diff --git a/docs/web.md b/docs/web.md index a364f0ad..4ab52557 100644 --- a/docs/web.md +++ b/docs/web.md @@ -5,3 +5,25 @@ Then go to [http://localhost:8080/vtm-web-app](http://localhost:8080/vtm-web-app) in the web browser to see the map. Hold right mouse button to change view direction. + +#### Debugging GWT app + +Using GWT SuperDevMode is the recommended way for development. Debugging in IDE is often not possible. + +For an introduction see [GWT](http://www.gwtproject.org/articles/superdevmode.html) and [libGDX](http://www.badlogicgames.com/wordpress/?p=3073) documentations. + +- Serve the website as usual with `./gradlew :vtm-web-app:farmRun` command. + +- The codeserver must be executed on another shell. +```bash +export _JAVA_OPTIONS="-Xmx1024m" +./gradlew :vtm-web-app:gwtSuperDev +``` + +- Open the link of codeserver: `The code server is ready at http://127.0.0.1:xxxx/` + +- Drag the two bookmarklets to your browser's bookmark bar. + +- Visit your [web page](http://localhost:8080/vtm-web-app) and click **Dev Mode On** to start development mode. + +- Press **F12** to open the developer tools of your browser. Now you can debug your code under **Sources**. \ No newline at end of file diff --git a/vtm-web/HOWTO-SuperDevMode.txt b/vtm-web/HOWTO-SuperDevMode.txt deleted file mode 100644 index f87143bf..00000000 --- a/vtm-web/HOWTO-SuperDevMode.txt +++ /dev/null @@ -1,14 +0,0 @@ -Using GWT SuperDevMode is the recommended way for development. - -For an introduction see: - -http://www.gwtproject.org/articles/superdevmode.html -http://www.badlogicgames.com/wordpress/?p=3073 - -Running: -- Serve the website -$../gradlew jettyDraftWar - -- The codeserver can be executed on another shell -$export _JAVA_OPTIONS="-Xmx1024m" -$../gradlew gwtSuperDev