-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Abide does not work with Ember.js #3206
Comments
Can you post your code? |
I have the same issue, Abide is AWOL and no errors. I considered that <form class="form-inline" data-abide="data-abide" data-ember-action="55">
<fieldset>
<div class="row">
<div class="small-12 columns" data-bindattr-56="56">
<label>Card Number<input id="ember2328" class="ember-view ember-text-field form-number" type="text" pattern="[a-zA-Z]+" required="required"></label><script id="metamorph-1476-start" type="text/x-placeholder">
</script><script id="metamorph-1476-end" type="text/x-placeholder">
</script>
</div>
</div>
</fieldset>
</form> Ran foundation again $(document).foundation() Also added the small error field thingy not shown in HTML above. No dice. |
Got it working by pasting the code for abide into console and rerunning https://github.com/zurb/foundation/blob/master/js/foundation/foundation.abide.js |
I'm having the same problem, but @theworkerant's solution doesn't work for me. |
@ekampp Yea I gave up. |
Pity. |
There's a fix for this, although it's a pity it is needed. For example, I've made a RouteDefault, which is inherited by all Routes:
So now for example the IndexRoute:
On every pagerender/view It's hackish, but at least it works.... |
Just a small update. You can even fix this easier. Include a scriptcall to the orbit.js file (or a concatted version of all foundation plugins) in a template. For example: I'm using a footer.hbs which is used on each Ember template:
All my own methods + needed foundation plugins are reloaded on each pageview. Seems to be working perfectly. No need to use a setTimeout when using this method. |
It seems like a large load, to reload every js file from foundation every time. 😞 |
Shouldn't there be a good javascripty reason for this happening in the first place? I was hoping someone who wrote the code might be able to point out some internal method to do this reload gracefully. Reloading the whole enchilada is kind of silly, although the best solution so far. |
If the foundation files are already loaded somewhere in the DOM, I guess that you can observe, when ever the basis view changes, and then reload the |
Calling |
@theworkerant It's got to do with "forms.on('submit validate)....." [line 64~89 @abide.js]. You can't really bind custom validation rules correctly when changing the entire dom on-the-fly continuously. Might be a way to fix it, I just don't know how to :(
and
... still no dice. Got some results, but it's still not reliable enough. Kept debugging this... what works for me is to only reload foundation.abide.js on a pageview end THEN call |
@garvo Changing the event bindings didn't work? |
Unfortunately we're unable to support Foundation and Ember.js – if there's a pull request to correct this that is not impactful of other JS frameworks we'll consider that and merge it. |
This blew up for me with emberjs as well, and here is how I solved it : http://stackoverflow.com/questions/23877396/emberjs-embercli-foundation-5-scrolltop-undefined-on-mobile-responsive/23880012 with closed on zurb ticket #5226 |
When you combine Foundation with Ember.js, Abide stops working for no reason.
The text was updated successfully, but these errors were encountered: