This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Sample usage - note that the trailing slash on the watch directory is important! | |
* | |
* node uglify.js /path/to/my/src/directory/ /path/to/my/output/file.js | |
*/ | |
var jsp = require('uglify-js').parser, | |
pro = require('uglify-js').uglify, | |
fs = require('fs'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.alert("Hello world!"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.alert("Hello World!", function() { | |
// any code you want to happen after the alert is dismissed | |
console.log("Alert dismissed"); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.alert("Custom label text!", "Very good."); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.confirm("Are you sure?"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.confirm("Are you sure?", function(result) { | |
if (result) { | |
console.log("User confirmed dialog"); | |
} else { | |
console.log("User declined dialog"); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.confirm("Are you sure?", "No way!", "Yes, definitely!", function(result) { | |
console.log("Confirmed? "+result); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.dialog("Hello there!"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.dialog("Hi there!", { | |
"label": "OK", | |
"callback": function() { | |
console.log("callback"); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bootbox.dialog("Hi there!", { | |
"OK": function() { | |
console.log("callback"); | |
} | |
}); |