File tree Expand file tree Collapse file tree 4 files changed +34
-0
lines changed
Expand file tree Collapse file tree 4 files changed +34
-0
lines changed Original file line number Diff line number Diff line change @@ -58,6 +58,18 @@ npm test
5858
5959_ NOTE: You will need node-gyp installed using "npm install -g node-gyp"_
6060
61+ ## Installation node-webkit
62+
63+ ``` bash
64+ npm install -g nw-gyp
65+ npm install java
66+ cd node_modules/java
67+ nw-gyp configure --target=0.10.5
68+ nw-gyp build
69+ ```
70+
71+ _ See testIntegration/webkit for a working example_
72+
6173## Quick Examples
6274
6375``` javascript
Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html >
3+ < head >
4+ < title > Hello World!</ title >
5+ < script type ="text/javascript " src ="main.js "> </ script >
6+ </ head >
7+ < body >
8+ < h1 > Hello World!</ h1 >
9+ We are using java: < script > document . write ( runJavaMethod ( ) ) </ script > .
10+ </ body >
11+ </ html >
Original file line number Diff line number Diff line change 1+ var java = require ( '../../' ) ;
2+
3+ function runJavaMethod ( ) {
4+ return java . callStaticMethodSync ( "java.lang.System" , "getProperty" , "java.version" ) ;
5+ }
Original file line number Diff line number Diff line change 1+ {
2+ "name" : " webkitIntegrationTest" ,
3+ "version" : " 0.0.0" ,
4+ "description" : " " ,
5+ "main" : " index.html"
6+ }
You can’t perform that action at this time.
0 commit comments