/**
 * Get array of individual lines in the string.
 *
 * @return array Returns array of lines.
 */
public function lines(): array

Examples

$lines = Strings::create("Fòô òô\n fòô fò fò \nfò\r")->lines();

echo $lines;

The above example will output:

Array
(
    [0] => Fòô òô
    [1] =>  fòô fò fò
    [2] => fò
)

Getting Started

Methods