<commit_before>String.prototype.trimRight <sup>[![Version Badge][npm-version-svg]][package-url]</sup>

[![Build Status][travis-svg]][travis-url]
[![dependency status][deps-svg]][deps-url]
[![dev dependency status][dev-deps-svg]][dev-deps-url]
[![License][license-image]][license-url]
[![Downloads][downloads-image]][downloads-url]

[![npm badge][npm-badge-png]][package-url]

[![browser support][testling-svg]][testling-url]

A ES2019-spec-compliant `String.prototype.trimRight` shim. Invoke its "shim" method to shim `String.prototype.trimRight` if it is unavailable.

This package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment and complies with the [spec](http://www.ecma-international.org/ecma-262/6.0/#sec-object.assign). In an ES6 environment, it will also work properly with `Symbol`s.

Most common usage:
```js
var trimRight = require('string.prototype.trimright');

assert(trimRight(' \t\na \t\n') === 'a \t\n');

if (!String.prototype.trimRight) {
	trimRight.shim();
}

assert(trimRight(' \t\na \t\n ') === ' \t\na \t\n '.trimRight());
```

## Tests
Simply clone the repo, `npm install`, and run `npm test`

[package-url]: https://npmjs.com/package/string.prototype.trimright
[npm-version-svg]: http://vb.teelaun.ch/es-shims/String.prototype.trimRight.svg
[travis-svg]: https://travis-ci.org/es-shims/String.prototype.trimRight.svg
[travis-url]: https://travis-ci.org/es-shims/String.prototype.trimRight
[deps-svg]: https://david-dm.org/es-shims/String.prototype.trimRight.svg
[deps-url]: https://david-dm.org/es-shims/String.prototype.trimRight
[dev-deps-svg]: https://david-dm.org/es-shims/String.prototype.trimRight/dev-status.svg
[dev-deps-url]: https://david-dm.org/es-shims/String.prototype.trimRight#info=devDependencies
[testling-svg]: https://ci.testling.com/es-shims/String.prototype.trimRight.png
[testling-url]: https://ci.testling.com/es-shims/String.prototype.trimRight
[npm-badge-png]: https://nodei.co/npm/string.prototype.trimright.png?downloads=true&stars=true
[license-image]: http://img.shields.io/npm/l/string.prototype.trimright.svg
[license-url]: LICENSE
[downloads-image]: http://img.shields.io/npm/dm/string.prototype.trimright.svg
[downloads-url]: http://npm-stat.com/charts.html?package=string.prototype.trimright<commit_msg>[readme] fix repo URLs; remove travis badge<commit_after>String.prototype.trimRight <sup>[![Version Badge][npm-version-svg]][package-url]</sup>

[![dependency status][deps-svg]][deps-url]
[![dev dependency status][dev-deps-svg]][dev-deps-url]
[![License][license-image]][license-url]
[![Downloads][downloads-image]][downloads-url]

[![npm badge][npm-badge-png]][package-url]

[![browser support][testling-svg]][testling-url]

A ES2019-spec-compliant `String.prototype.trimRight` shim. Invoke its "shim" method to shim `String.prototype.trimRight` if it is unavailable.

This package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment and complies with the [spec](https://262.ecma-international.org/6.0/#sec-object.assign). In an ES6 environment, it will also work properly with `Symbol`s.

Most common usage:
```js
var trimRight = require('string.prototype.trimright');

assert(trimRight(' \t\na \t\n') === 'a \t\n');

if (!String.prototype.trimRight) {
	trimRight.shim();
}

assert(trimRight(' \t\na \t\n ') === ' \t\na \t\n '.trimRight());
```

## Tests
Simply clone the repo, `npm install`, and run `npm test`

[package-url]: https://npmjs.com/package/string.prototype.trimright
[npm-version-svg]: https://vb.teelaun.ch/es-shims/String.prototype.trimRight.svg
[deps-svg]: https://david-dm.org/es-shims/String.prototype.trimRight.svg
[deps-url]: https://david-dm.org/es-shims/String.prototype.trimRight
[dev-deps-svg]: https://david-dm.org/es-shims/String.prototype.trimRight/dev-status.svg
[dev-deps-url]: https://david-dm.org/es-shims/String.prototype.trimRight#info=devDependencies
[testling-svg]: https://ci.testling.com/es-shims/String.prototype.trimRight.png
[testling-url]: https://ci.testling.com/es-shims/String.prototype.trimRight
[npm-badge-png]: https://nodei.co/npm/string.prototype.trimright.png?downloads=true&stars=true
[license-image]: https://img.shields.io/npm/l/string.prototype.trimright.svg
[license-url]: LICENSE
[downloads-image]: https://img.shields.io/npm/dm/string.prototype.trimright.svg
[downloads-url]: https://npm-stat.com/charts.html?package=string.prototype.trimright
{'fraction_non_alphanumeric': 0.189363595905652, 'fraction_numerical': 0.004895416110369382, 'mean_word_length': 5.348870056497175, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 25, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 12, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5337384', 'n_tokens_mistral': 1656, 'n_tokens_neox': 1596, 'n_words': 243}