Card(color, symbol)

UNO card class.

new Card(color, symbol)

Creates a new UNO Card.

Parameters:
Name Type Description
color string

The color of the card. Either red, yellow, green, blue, or wild.

symbol string

The number (in string) or symbol of the card. Check cardTypes for lists of valid symbols and its name.

Members

color :string

The color of the card.

name :string

The name of the card.

number :number

The number of the card. An alias for Symbol properties if the card is a number card.

points :number

The points of the card.

symbol :string

The number (in string) or symbol of the card.

Methods

toString() → {string}

Returns a string representation of UNO Card.

Returns:
string

static toString() → {string}

Returns the name of the class.

Returns:
string