mirror of
https://github.com/github/codeql-action.git
synced 2025-12-31 11:40:24 +08:00
The [release notes](https://github.com/avajs/ava/releases/tag/v4.3.3) mention compatibility with Node 18.8.
40 lines
678 B
Markdown
40 lines
678 B
Markdown
# convert-to-spaces [](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`<br>
|
|
Default: `2`
|
|
|
|
Number of spaces instead of each tab.
|
|
|
|
## Related
|
|
|
|
- [convert-to-tabs](https://github.com/vadimdemedes/convert-to-tabs) - Convert spaces to tabs.
|