Skip to content

Commit

Permalink
Merge pull request #14 from nucreativa/add-locale-in_ID
Browse files Browse the repository at this point in the history
Add locale in
  • Loading branch information
hustcc authored Sep 10, 2016
2 parents dfe37af + ebb90cc commit 247d239
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
18 changes: 18 additions & 0 deletions locales/in_ID.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module.exports = function(number, index) {
return [
['baru saja', 'sebentar'],
['%s detik yang lalu', 'dalam %s detik'],
['1 menit yang lalu', 'dalam 1 menit'],
['%s menit yang lalu', 'dalam %s menit'],
['1 jam yang lalu', 'dalam 1 jam'],
['%s jam yang lalu', 'dalam %s jam'],
['1 hari yang lalu', 'dalam 1 hari'],
['%s hari yang lalu', 'dalam %s hari'],
['1 minggu yang lalu', 'dalam 1 minggu'],
['%s minggu yang lalu', 'dalam %s minggu'],
['1 bulan yang lalu', 'dalam 1 bulan'],
['%s bulan yang lalu', 'dalam %s bulan'],
['1 tahun yang lalu', 'dalam 1 tahun'],
['%s tahun yang lalu', 'dalam %s tahun']
][index];
}
2 changes: 1 addition & 1 deletion tests/locales_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ var fs = require('fs');
var test = require('tape');
var timeago = require('..');

var tobeTested = ['en', 'zh_CN', 'fr', 'nl_BE', 'pt_BR', 'da']; // when add a new locale, add locale's name here
var tobeTested = ['en', 'zh_CN', 'fr', 'nl_BE', 'pt_BR', 'da', 'in_ID']; // when add a new locale, add locale's name here

test('Testing locales', function (t) {
for (var i = 0; i < tobeTested.length ; i++) {
Expand Down

0 comments on commit 247d239

Please sign in to comment.