We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Bump.type( { init: function( name ) { this._name = name; }, members: { nameSquared: function() { return this.name.length * this.name.length; } }, properties: { name: { get: function() { return this._name; } } } } );
By default defines a create function on the returned type that passes arguments to init.
create
Returns:
A new Type object
Parameters:
parent: parent Type object init: constructor method. include a function name. members: object listing name/object pairs typically methods properties: object listing name/object pairs that become properties typeMembers: object listing name/object pairs attached to the returned type object