mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-02 08:07:50 +00:00
Simplify asciiSize.
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
import baseProperty from './.internal/baseProperty.js';
|
||||
|
||||
/**
|
||||
* Gets the size of an ASCII `string`.
|
||||
*
|
||||
@@ -7,6 +5,8 @@ import baseProperty from './.internal/baseProperty.js';
|
||||
* @param {string} string The string inspect.
|
||||
* @returns {number} Returns the string size.
|
||||
*/
|
||||
const asciiSize = baseProperty('length');
|
||||
function asciiSize({ length }) {
|
||||
return length;
|
||||
}
|
||||
|
||||
export default asciiSize;
|
||||
|
||||
Reference in New Issue
Block a user