Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MODAL: Option "backdrop" provided type "undefined" #64

Open
archonic opened this issue Feb 9, 2018 · 2 comments
Open

MODAL: Option "backdrop" provided type "undefined" #64

archonic opened this issue Feb 9, 2018 · 2 comments

Comments

@archonic
Copy link

archonic commented Feb 9, 2018

I'm getting this with bootstrap 4:

MODAL: Option "backdrop" provided type "undefined" but expected type "(boolean|string)"

The link is just

link_to 'Cancel account', registration_path(resource_name), method: :delete, class: 'btn btn-danger', data: { confirm: 'Are you sure?' }

I'm thinking the version of BS 4 I'm running changed the argument requirements. Looking at data-confirm-modal.js, it looks like it plugs the data attributes directly into the BS modal function without conferring with defaults. Should backdrop, keyboard and show be using ||= instead?

@camilleroux
Copy link

Same error here. Can I help giving you more information?

@archonic
Copy link
Author

Because this gem basically just wraps one JS file, I took out that file, modified it for only supporting BS4, converted it to coffee and fixed the error seen here.

Here's the gist. https://gist.github.com/archonic/8a9392a005d0bc1ab621c69619825afe

I'll leave the issue open because I think this gem is broken out of the box for bootstrap 4 post-release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants