Skip to content

Commit

Permalink
Require Node.js 14
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Mar 20, 2023
1 parent 02dae42 commit 450bb49
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 20 deletions.
10 changes: 5 additions & 5 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Trim from the start and end of a string.
@example
```js
import trimNewlines from 'trim-newlines';
import {trimNewlines} from 'trim-newlines';
trimNewlines('\n🦄\n🦄\r\n');
//=> '🦄\n🦄'
Expand All @@ -29,9 +29,9 @@ Trim from the start of a string.
@example
```js
import trimNewlines from 'trim-newlines';
import {trimNewlinesStart} from 'trim-newlines';
trimNewlines.start('\n🦄\r\n');
trimNewlinesStart('\n🦄\r\n');
//=> '🦄\r\n'
```
*/
Expand All @@ -42,9 +42,9 @@ Trim from the end of a string.
@example
```js
import trimNewlines from 'trim-newlines';
import {trimNewlinesEnd} from 'trim-newlines';
trimNewlines.end('\n🦄\r\n');
trimNewlinesEnd('\n🦄\r\n');
//=> '\n🦄'
```
*/
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"type": "module",
"exports": "./index.js",
"engines": {
"node": ">=12"
"node": ">=14.16"
},
"scripts": {
"test": "xo && ava && tsd"
Expand Down
16 changes: 2 additions & 14 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ Looking to trim all whitespace, not just newlines? Use `String#trim()`, `String#

## Install

```
$ npm install trim-newlines
```sh
npm install trim-newlines
```

## Usage
Expand Down Expand Up @@ -38,15 +38,3 @@ Trim from the start of a string.
### trimNewlinesEnd(string)

Trim from the end of a string.

---

<div align="center">
<b>
<a href="https://tidelift.com/subscription/pkg/npm-trim-newlines?utm_source=npm-trim-newlines&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
</b>
<br>
<sub>
Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
</sub>
</div>

0 comments on commit 450bb49

Please sign in to comment.