AngularJS : Differences among = & @ in directive scope? [duplicate]
问题 This question already has answers here : What is the difference between '@' and '=' in directive scope in AngularJS? (18 answers) Closed 5 years ago . Creating an isolate scope inside a directive lets us map the outer scope to the inner scope . We have seen six different ways to map to attrbutes: =attr &attr @attr = & @ What do each of these scope mapping options do? 回答1: This can be confusing but hopefully a simple example will clarify it. First, let's separate model bindings from behaviors.