Closed joskuijpers closed 10 years ago
Erhm, I think I accidentally reformatted the whole bootbox.js file using my on-save JS beautify script. The top line of the bootbox.js stacktrace should read line 702.
Hi @joskuijpers,
This is a classic symptom of the required Bootstrap JS not being loaded. I know you've mentioned it in your list of dependencies but it's worth double checking you're loading the JS, not just the CSS. Let me know if that's the cause - I might put a clearer console warning in about this.
Warning error added, scheduled for 4.4.0 (#300)
You are right! Thank you! I did not use the bootstrap JS because I use angular-bootstrap :)
hi joskuijpers did you get solution yet... i also need to add bootbox in angular, but how can i do?
The answer given above solved it for me :) I had to add the bootstrap javascrit file to my html.
On Nov 11, 2014, at 12:46 PM, Salman Ismail notifications@github.com wrote:
hi joskuijpers did you get solution yet... i also need to add bootbox in angular, but how can i do?
— Reply to this email directly or view it on GitHub.
Can we better check for the existence of Bootstrap.js? I mean, this will never be "hot" code. It would make more sense not to have everyone bit by this. Bootstrap.js does a reasonable job being sane about this. It's the very first thing it does..
if (typeof jQuery === 'undefined') {
throw new Error('Bootstrap\'s JavaScript requires jQuery')
}
this question has detection code for Bootstrap.js v3.
// Will be true if bootstrap 3 is loaded, false if bootstrap 2 or no bootstrap
var bootstrap3_enabled = (typeof $().emulateTransitionEnd == 'function');
patch created
Hi!
I am using Bootstrap 3.2, angular-bootstrap 0.11.0 and angular 1.2.21. I simply installed bootbox using bower install (4.3.0), and tried using
bootbox.alert('Hello World!');
This is what I get:
The 'dialog' variable, where the modal function is called on, does indeed not contain such function.
What is going on here? Might it be the angular ui bootstrap package?
Hope to hear what the troubles might be. I am wanting to use bootbox for error display and removal-confirmation.