<!doctype html>
<html xmlns:ng="http://angularjs.org">
<script type="text/javascript" src="http://code.angularjs.org/angular-0.9.5.js" ng:autobind></script>
<body>
<input type="checkbox" name="enabled" checked/>
<input type="text" name="name" disabled="{{!enabled}}" value="abc" />
enabled={{enabled|json}}
</body>
</html>
--
You received this message because you are subscribed to the Google Groups "Angular" group.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/angular?hl=en.
I think I occasionally see this issue too. It usually goes away after
the next reload, right?
>
> The UI I'm working on is a bit complicated, with the disabled state of
> some form fields depending on the state of other form fields in
> conjunction with rules embedded in the model. In an attempt to keep
> things DRY I'm using getters to represent this state in the model,
> rather than manually keeping a boolean flag in sync with some other
> arbitrarily complicated aspect of the model.
that's how it's supposed to be done.
>
> var foo = {
> ...
> get bar() { /*returns boolean*/ },
> ...
> };
>
> then in the markup:
>
> <input type="text" disabled="{{bar}}">
>
> Anyway I thought I'd make note of it here in case it helps.
thanks!
more feedback more better :-)
/i
> To unsubscribe from this group, send email to angular+u...@googlegroups.com.
please do. thanks!
/i