# convert-to-spaces **Repository Path**: mirrors_vadimdemedes/convert-to-spaces ## Basic Information - **Project Name**: convert-to-spaces - **Description**: Convert tabs to spaces in a string - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-09-26 - **Last Updated**: 2025-09-20 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # convert-to-spaces [![Build Status](https://github.com/vadimdemedes/convert-to-spaces/workflows/test/badge.svg)](https://github.com/vadimdemedes/convert-to-spaces/actions) > Convert tabs to spaces in a string ## Install ``` $ npm install --save convert-to-spaces ``` ## Usage ```js import convertToSpaces from 'convert-to-spaces'; convertToSpaces('\t\thello!'); //=> ' hello!' ``` ## API ### convertToSpaces(input, [spaces]) #### input Type: `string` String to convert. #### spaces Type: `number`
Default: `2` Number of spaces instead of each tab. ## Related - [convert-to-tabs](https://github.com/vadimdemedes/convert-to-tabs) - Convert spaces to tabs.