yamadapc/js-written-number

Fractions and non-integer numbers

Open

#2 opened on Apr 17, 2015

View on GitHub
 (9 comments) (0 reactions) (0 assignees)JavaScript (121 forks)github user discovery
enhancementhelp wanted

Repository metrics

Stars
 (372 stars)
PR merge metrics
 (PR metrics pending)

Description

Neat lib, thanks for the clean & easy to scan code!

it('correctly converts numbers < 0', function() {
  writtenNumber(0.5).should.equal('half');
  writtenNumber('1/3').should.equal('a third'); // one third?
  writtenNumber('0.333333333').should.equal('a third'); // one third?
  writtenNumber('0.1').should.equal('a tenth'); // one tenth?
  writtenNumber('1/16').should.equal('a sixteenth');
});

Might be out of scope?

Contributor guide