I am checking out the "Promises/A+" Specification, but could not understand the following things:
On Section 1. Terminology,
1.1. "promise”
is an object or function with a then method whose behavior conforms to this specification.
1.2. “thenable”
is an object or function that defines a then method.
So What is the difference between the terms "thenable"
and "promise"
?
Also in Section 2.3. The Promise Resolution Procedure,
The promise resolution procedure is an abstract operation taking as input a promise and a value, which we denote as [[Resolve]](promise, x)
.
So my question is:
Why is it denoted within 2 opening and closing brackets? Is there any convention?
Thank you very much.
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…