Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lablnet/javascript-language-selector
Create your frontend website in multiple languages by using this class.
https://github.com/lablnet/javascript-language-selector
class free frontend javascript js language mit plugin selector websitem
Last synced: about 1 month ago
JSON representation
Create your frontend website in multiple languages by using this class.
- Host: GitHub
- URL: https://github.com/lablnet/javascript-language-selector
- Owner: lablnet
- License: mit
- Created: 2019-08-16T02:41:08.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-06-07T15:25:03.000Z (over 1 year ago)
- Last Synced: 2023-06-07T16:39:24.340Z (over 1 year ago)
- Topics: class, free, frontend, javascript, js, language, mit, plugin, selector, websitem
- Language: JavaScript
- Homepage: https://lablnet.github.io/Javascript-Language-Selector/
- Size: 7.81 KB
- Stars: 7
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Javascript Langauge Selector
Create your frontend website in multiple languages by using this class.
### Features
- Simple but yet powerful.
- Enable RTL automatically.
- Super fast.
- Much more...### Demo
- [https://lablnet.github.io/Javascript-Language-Selector/](https://lablnet.github.io/Javascript-Language-Selector/)### Requirement
- Jquery### How to use?
- Just download this code or clone
- ```
git clone https://github.com/Lablnet/Javascript-Language-Selector.git```
- Include the `js` file in `head` section of your page
- ```html
- Make sure jquery is included in your page- Load the language file which contain json data
- ```html
```
- The `locale.js` file contains language strings something like
- ```js lang = {
'en': {
':heading': 'Javascript Language Selector',
':h2': 'This is the sub heading',
':first:p': "Hey! this is the javascript language selector",
':english': 'English',
':urdu': 'Urdu',
':portuguese': 'Portuguese',
':choose': 'Choose the language',
},
}
- Now write your markup/html
- ```html
:heading
:h2
:first:p
- Parse language
- ```js
var l = new LanguageSelector();
l.parse();
- That's all.### LICENSE
- MIT### Author
[Muhammad Umer Farooq](https://lablnet.github.io/profile/)