JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 92235
  • Score
    100M100P100Q162657F
  • License MIT

ember-inflector goal is to be rails compatible.

Package Exports

  • ember-inflector
  • ember-inflector/addon

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (ember-inflector) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Ember Inflector Build Status

Ember Inflector is a library for inflecting words between plural and singular forms. Ember Inflector aims to be compatible with ActiveSupport::Inflector from Ruby on Rails, including the ability to add your own inflections in your app.

Installation

Ember CLI/NPM:

npm install --save ember-inflector

Usage

All methods are always available from Ember.Inflector, but in Ember CLI, you can always import instead:

import Inflector from 'ember-inflector';
import {singularize, pluralize} from 'ember-inflector';

Inflector.inflector.singularize("tacos"); // taco
Inflector.inflector.pluralize("taco"); // tacos

singularize("tacos"); // taco
pluralize("taco"); // tacos

// or if not using Ember CLI/ES6
Ember.Inflector.inflector.pluralize("taco"); // tacos