formatWithArgs

fun String.formatWithArgs(vararg args: Any): String

Extension function to format a Swift/Kotlin String using Cocoa's NSString engine.

Supports formatting up to 4 arguments by mapping them to appropriate NSString initialization hooks.

Return

The formatted string.

Parameters

args

The format arguments to apply.