|
Lumpy posted:So I'm going to start messing about with one of these MV* things for fun, and I've looked at sample code / tutorials for a few, and Ember makes a lot more intuitive sense to me, but all the chit-chat from all the skinny jeans kids on the internet seems to be about Angular. Is this just because of and it's just the flavor of the month, or is Angular on it's way to becoming the jQuery of client side app frameworks? A little bit of both? Angular is a super powerful framework, but it's not without its warts and issues. After taking a look at EmberJS over the past couple of days I'm intrigued enough that I'd like to know more. I have a set of issues with Angular that don't look like they're going away anytime soon, but look like they're somewhat solved in Ember.
|
# ¿ Oct 2, 2013 17:23 |
|
|
# ¿ May 7, 2024 01:51 |
|
an skeleton everything you're doing just sounds... wrong. Anyway. AngularJS allows the arbitrary nesting of forms via the ng-form tag. Sub-forms will propagate their validity up to their parent forms. I made you a jsFiddle and everything because I'm bored. http://jsfiddle.net/jK72r/ The validation of subForm propagates up to myForm.
|
# ¿ Feb 5, 2014 02:20 |
|
What about it didn't work? Works fine in the jsFiddle. Maybe there is some scope wackiness on the go with the ngGrid stuff? I've never used ngGrid before. Do you have a top level form that contains everything?
|
# ¿ Feb 6, 2014 00:08 |
|
excidium posted:So I've wrote an app that I'm going to publish and it works fine and dandy. This is the first time I've really used AngularJS and wrote a non-trivial JS app. I really want to take my work now and learn from my mistakes to improve my efficiency going forward. I feel like a major sticking point is code repetition. Looking at this snippet, what can I do to improve this code? I have a bunch of different calculations and they are all set up exactly like this. It seems like the favorite stuff should be easy to extract but I'm not sure where to start. There is nothing all that magical about AngularJS controllers. At our company we use a mixin pattern to separate out common functionality. See here for an example: http://digital-drive.com/?p=188
|
# ¿ Feb 19, 2014 07:36 |