concat (Standard - JavaScript)

Concatenates strings.

Defined in

String (Standard - JavaScript)

Syntax

concat(str:string, ...) : string
Parameters Description
str A string to be concatenated to this object. You can specify multiple parameters.
Return value Description
string The concatenated strings.

Usage

Each parameter is a string that is concatenated to the base string in order.

Examples

The following example returns Paris Moscow Tokyo.
var cities = new String("Paris");
cities.concat("   Moscow", "   Tokyo")