We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Amber has the following methods which can be used to call JS constructors that take arguments:
BlockClosure>>#newValue:
BlockClosure>>#newValue:value:
BlockClosure>>#newValue:value:value:
Examples:
new Foo(); // JS version Foo new. "Amber version" new Foo(1,2); // JS version Foo newValue: 1 value: 2. "Amber version"
This recipe was posted to the Amber mailinglist by Andy Bower.
Literal notation may be used for arguments.
More on Smalltalk and JavaScript