Socket
Socket
Sign inDemoInstall

deep-trim-node

Package Overview
Dependencies
0
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    deep-trim-node

Recursively String.trim() object properties of type String.


Version published
Maintainers
1
Install size
8.56 kB
Created

Readme

Source

⚠️ This package is deprecated.

deep-trim-node Logo

Recursively String.trim() object properties of type String.

NPM Package Version NPM Package Downloads NPM Package License

Installation

npm install deep-trim-node

Usage Example

var trim = require('deep-trim-node');

var person = {
  name: '   John   ',
  surname: 'Johnson   ',
  age: 26,
  address: {
    street: '1st Street',
    city: 'Los Angeles',
    country: ' USA   ',
  },
  vehicles: ['   BMW', 'Ferrari    ', 'Lamborghini'],
};

person = trim(person);

console.log(person);

{
    name: 'John',
    surname: 'Johnson',
    age: 26,
    address: {
        street: '1st Street',
        city: 'Los Angeles',
        country: 'USA'
    },
    vehicles: [
        'BMW',
        'Ferrari',
        'Lamborghini'
    ]
}

Tests

To run the test suite, first install the dependencies, then run npm test:

$ npm install
$ npm test

License

Distributed under the MIT License.

Keywords

FAQs

Last updated on 12 Jan 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc