inflection icon indicating copy to clipboard operation
inflection copied to clipboard

Doesn't seem to work at all with modern Node (0.8.8)

Open tlhunter opened this issue 12 years ago • 2 comments

Code:

var singularize = require("inflection").singularize;
console.log(singularize('bananas'));

Output:

/blah/node_modules/inflection/lib/inflection.js:271
      return this._apply_rules( str, singular_rules, uncountable_words, singul
                  ^
TypeError: Object #<Object> has no method '_apply_rules'
    at inflector.singularize (/blah/node_modules/inflection/lib/inflection.js:271:19)
    at Object.<anonymous> (/blah/node_modules/easyxml/index.js:2:13)
    at Module._compile (module.js:449:26)
    at Object.Module._extensions..js (module.js:467:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:362:17)
    at require (module.js:378:17)
    at Object.<anonymous> (/blah/server.js:1:77)
    at Module._compile (module.js:449:26)

tlhunter avatar Sep 24 '12 19:09 tlhunter

tlhunter , I think you're confused. I have the same error, but I've noticed that when you install the module with "npm install inflection". You are installing the repository https://github.com/dreamerslab/node.inflection

dmiro avatar May 22 '13 17:05 dmiro

please try to install the latest version v1.2.6

ben-lin avatar May 24 '13 16:05 ben-lin