/ LJCPHPCodeDoc / LJCTextBuilderLib / LJCTextBuilder / EndsWithNewLine


Returns

true if builder text ends with a newline; otherwise false.

Syntax

JavaScript
EndsWithNewLine()

Indicates if the builder text ends with a newline.

Example

JavaScript
// Indicates if the builder text ends with a newline.
EndsWithNewLine()
{
  const tb = new LJCTextBuilder();
  tb.Text("This text ends with a newline.\r\n");

  // Example Method:
  const result = tb.EndsWithNewLine();

  // result:
  // "true"
}

Copyright © Lester J. Clark and Contributors.
Licensed under the MIT License.