remove closure compiler instructions; close #2193

This commit is contained in:
Vladimir Agafonkin 2013-11-15 16:35:25 +02:00
parent 00e0dcf3e5
commit 58b93f80b1
3 changed files with 8 additions and 21 deletions

View File

@ -86,21 +86,14 @@
<li><a href="http://nodejs.org/#download">Download and install Node</a></li> <li><a href="http://nodejs.org/#download">Download and install Node</a></li>
<li>Run this in the command line:<br /> <li>Run this in the command line:<br />
<pre><code>npm install -g jake <pre><code>npm install -g jake
npm install jshint npm install</code></pre></li>
npm install uglify-js</code></pre></li>
<li>Run this command inside the Leaflet directory: <br /><input type="text" id="command2" /> <li>Run this command inside the Leaflet directory: <br /><input type="text" id="command2" />
</ol> </ol>
<h2>Building using Closure Compiler</h2>
<ol>
<li><a href="http://closure-compiler.googlecode.com/files/compiler-latest.zip">Download Closure Compiler</a>, extract it into <code>closure-compiler</code> directory</li>
<li>Run this command in the root Leaflet directory: <br /><input type="text" id="command" /></li>
</ol>
</div> </div>
<script type="text/javascript"> <script type="text/javascript">
var deplist = document.getElementById('deplist'), var deplist = document.getElementById('deplist'),
commandInput = document.getElementById('command'), commandInput = document.getElementById('command2');
commandInput2 = document.getElementById('command2');
document.getElementById('select-all').onclick = function() { document.getElementById('select-all').onclick = function() {
var checks = deplist.getElementsByTagName('input'); var checks = deplist.getElementsByTagName('input');
@ -139,15 +132,7 @@ npm install uglify-js</code></pre></li>
} }
} }
var command = 'java -jar closure-compiler/compiler.jar '; commandInput.value = 'jake build[' + parseInt(compsStr, 2).toString(32) + ',custom]';
for (var src in files) {
command += '--js src/' + src + ' ';
}
command += '--js_output_file dist/leaflet-custom.js';
commandInput.value = command;
commandInput2.value = 'jake build[' + parseInt(compsStr, 2).toString(32) + ',custom]';
} }
function inputSelect() { function inputSelect() {
@ -156,7 +141,6 @@ npm install uglify-js</code></pre></li>
}; };
commandInput.onclick = inputSelect; commandInput.onclick = inputSelect;
commandInput2.onclick = inputSelect;
function onCheckboxChange() { function onCheckboxChange() {
if (this.checked) { if (this.checked) {

View File

@ -22,16 +22,18 @@ function getFiles(compsBase32) {
for (var i in deps) { for (var i in deps) {
if (comps) { if (comps) {
if (parseInt(comps.pop(), 2) === 1) { if (parseInt(comps.pop(), 2) === 1) {
console.log('\t* ' + i); console.log(' * ' + i);
addFiles(deps[i].src); addFiles(deps[i].src);
} else { } else {
console.log('\t ' + i); console.log(' ' + i);
} }
} else { } else {
addFiles(deps[i].src); addFiles(deps[i].src);
} }
} }
console.log('');
var files = []; var files = [];
for (var src in memo) { for (var src in memo) {

View File

@ -231,6 +231,7 @@ var deps = {
'dom/PosAnimation.js', 'dom/PosAnimation.js',
'map/anim/Map.PanAnimation.js' 'map/anim/Map.PanAnimation.js'
], ],
heading: 'Animation',
desc: 'Core panning animation support.' desc: 'Core panning animation support.'
}, },