How to get last character of string in JavaScript

Strings
By Jad Joubran · 
Last updated Aug 18, 2022
const name = "Lewis";

name.at(-1);
s
String.at() on Learn JavaScript Blog