Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

inflected

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

inflected

A port of ActiveSupport's inflector to Node.js

  • 2.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
632K
decreased by-12.96%
Maintainers
1
Weekly downloads
 
Created

What is inflected?

The 'inflected' npm package provides a set of utility functions for inflecting words in the English language. This includes converting between singular and plural forms, camelizing and underscoring strings, and more.

What are inflected's main functionalities?

Pluralize

This feature allows you to convert a singular noun to its plural form.

const inflected = require('inflected');
console.log(inflected.pluralize('person')); // Outputs: people

Singularize

This feature allows you to convert a plural noun to its singular form.

const inflected = require('inflected');
console.log(inflected.singularize('people')); // Outputs: person

Camelize

This feature converts strings to CamelCase.

const inflected = require('inflected');
console.log(inflected.camelize('active_model')); // Outputs: ActiveModel

Underscore

This feature converts CamelCase strings to snake_case.

const inflected = require('inflected');
console.log(inflected.underscore('ActiveModel')); // Outputs: active_model

Humanize

This feature converts snake_case strings to human-readable format.

const inflected = require('inflected');
console.log(inflected.humanize('employee_salary')); // Outputs: Employee salary

Other packages similar to inflected

Keywords

FAQs

Package last updated on 15 Jun 2017

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc