DEV Community

Discussion on: Daily Challenge #1 - String Peeler

Collapse
 
centanomics profile image
Cent

JS

Codepen


const stringPeeler = text => {
  return text.length < 3 ? null : text.substr(1, text.length-2);
}