Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for Translation Strings as Keys #82

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .github/main.workflow
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
workflow "New workflow" {
on = "push"
resolves = ["Run Tests"]
}

action "Install Dependencies" {
uses = "actions/npm@master"
runs = "npm"
args = "install"
}

action "Run Tests" {
uses = "actions/npm@master"
runs = "npm"
args = "test"
needs = ["Install Dependencies"]
}
24 changes: 24 additions & 0 deletions .github/next-version.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
language: node_js
node_js:
- "0.10"
- "7"
install:
- npm install
script: npm run build
23 changes: 22 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
![NPM Montly Downloads](https://img.shields.io/npm/dm/lang.js.svg)
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/rmariuzzo/Lang.js/master/LICENSE)

<br>
<br>
<br>

## Installation

Different installation methods:
Expand All @@ -14,6 +18,16 @@ Different installation methods:
- Bower: `bower install lang.js`
- Manually: [Download latest release](https://github.com/rmariuzzo/Lang.js/releases/latest)

<br>
<br>
<br>

[![Are you interested in the next version?](.github/next-version.svg)](https://github.com/rmariuzzo/Lang.js/tree/next)

<br>
<br>
<br>

## Documentation

### Initialization
Expand Down Expand Up @@ -205,7 +219,7 @@ var lang = new Lang({
'en.fruits': {
'apple': 'apple|apples'
},
'es.greetings': {
'es.fruits': {
'apple': 'manzana|manzanas'
}
}
Expand Down Expand Up @@ -251,6 +265,9 @@ lang.choice('fruits.apple', 22);

This method act as an alias of [`choice()`](#choice).

<br>
<br>
<br>

## Development

Expand All @@ -260,6 +277,10 @@ This method act as an alias of [`choice()`](#choice).

**[Get help!](https://gitter.im/rmariuzzo/Lang.js)**

<br>
<br>
<br>

## Testing

To run the tests use the following commands:
Expand Down
2 changes: 1 addition & 1 deletion dist/lang.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "lang.js",
"version": "1.1.13",
"version": "1.1.14",
"description": "Laravel's Lang in JavaScript!",
"main": "src/lang.js",
"types": "index.d.ts",
Expand Down
Loading