Plovr demo
This commit is contained in:
4
Makefile
Normal file
4
Makefile
Normal file
@@ -0,0 +1,4 @@
|
||||
all:
|
||||
java -jar plovr.jar serve main.json
|
||||
build:
|
||||
java -jar plovr.jar build main.json > index.js
|
||||
10
main.html
Executable file
10
main.html
Executable file
@@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Closure Library + Plovr</title>
|
||||
<script src="http://localhost:9810/compile?id=main"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="output"></div>
|
||||
<script>main()</script>
|
||||
</body>
|
||||
</html>
|
||||
12
main.js
Normal file
12
main.js
Normal file
@@ -0,0 +1,12 @@
|
||||
|
||||
goog.provide('ol');
|
||||
|
||||
goog.require('ol.Map');
|
||||
goog.require('goog.dom');
|
||||
|
||||
ol.main = function() {
|
||||
goog.dom.getElement('output').innerHTML = 'test';
|
||||
}
|
||||
|
||||
window['main'] = ol.main;
|
||||
// or goog.exportSymbol('main', hello.main);
|
||||
36
main.json
Normal file
36
main.json
Normal file
@@ -0,0 +1,36 @@
|
||||
{
|
||||
"id": "main",
|
||||
|
||||
"inputs": "main.js",
|
||||
"paths": [
|
||||
"."
|
||||
],
|
||||
|
||||
"externs": [
|
||||
"//google_maps_api_v3.js"
|
||||
],
|
||||
|
||||
"define": {
|
||||
// "goog.dom.ASSUME_STANDARDS_MODE": true,
|
||||
"goog.DEBUG": true
|
||||
},
|
||||
|
||||
"mode": "ADVANCED",
|
||||
"level": "VERBOSE",
|
||||
|
||||
"checks": {
|
||||
// "accessControls": "ERROR",
|
||||
// "visibility": "ERROR"
|
||||
"checkTypes": "ERROR",
|
||||
"checkRegExp": "ERROR",
|
||||
"checkVars": "ERROR",
|
||||
"deprecated": "ERROR",
|
||||
"fileoverviewTags": "ERROR",
|
||||
"invalidCasts": "ERROR",
|
||||
"missingProperties": "ERROR",
|
||||
"nonStandardJsDocs": "ERROR",
|
||||
"undefinedVars": "ERROR"
|
||||
},
|
||||
|
||||
"jsdoc-html-output-path": "."
|
||||
}
|
||||
36
src/main.json
Normal file
36
src/main.json
Normal file
@@ -0,0 +1,36 @@
|
||||
{
|
||||
"id": "main",
|
||||
|
||||
"inputs": "main.js",
|
||||
"paths": [
|
||||
"."
|
||||
],
|
||||
|
||||
"externs": [
|
||||
"//google_maps_api_v3.js"
|
||||
],
|
||||
|
||||
"define": {
|
||||
// "goog.dom.ASSUME_STANDARDS_MODE": true,
|
||||
"goog.DEBUG": true
|
||||
},
|
||||
|
||||
"mode": "ADVANCED",
|
||||
"level": "VERBOSE",
|
||||
|
||||
"checks": {
|
||||
// "accessControls": "ERROR",
|
||||
// "visibility": "ERROR"
|
||||
"checkTypes": "ERROR",
|
||||
"checkRegExp": "ERROR",
|
||||
"checkVars": "ERROR",
|
||||
"deprecated": "ERROR",
|
||||
"fileoverviewTags": "ERROR",
|
||||
"invalidCasts": "ERROR",
|
||||
"missingProperties": "ERROR",
|
||||
"nonStandardJsDocs": "ERROR",
|
||||
"undefinedVars": "ERROR"
|
||||
},
|
||||
|
||||
"jsdoc-html-output-path": "."
|
||||
}
|
||||
Reference in New Issue
Block a user