Giter Site home page Giter Site logo

rosspitman / shiny.i18n Goto Github PK

View Code? Open in Web Editor NEW

This project forked from appsilon/shiny.i18n

0.0 0.0 0.0 333 KB

Shiny applications internationalisation made easy

Home Page: https://appsilon.github.io/shiny.i18n/

License: Other

R 94.86% Shell 5.14%

shiny.i18n's Introduction

shiny.i18n

Shiny applications internationalisation made easy!

Actually, you can use shiny.i18n as a standalone R package - shiny app is just a perfect usecase example.

Using it is very simple: just prepare your translation files in one of the supported formats, read them into your app using user-friendly shiny.i18n interface and surround your expressions to translate by a translator tag. Thanks to that your app will remain neat and readible.

For more informations check the Example section below!

Change languages and formats easy with shiny.i18n.

Source code

This library source code can be found on Appsilon Data Science's Github:
https://github.com/Appsilon/shiny.i18n/

How to install?

Note! This library is still in its infancy. Api might change in the future.

At the moment it's possible to install this library through devtools.

devtools::install_github("Appsilon/shiny.i18n")

To install previous version you can run:

devtools::install_github("Appsilon/shiny.i18n", ref = "0.1.0")

Example

You can find some basic examples in /inst/examples.

Translation file format

Currently shiny.i18n supports two formats:

  • csv - where each translation is in separate file translation_<LANGUAGE-CODE>.csv. Example of translation_pl.csv for Polish language you may find here: inst/examples/data/translation_pl.csv.

  • json - single json file translation.json with mandatory fields: "languages" with list of all language codes and "translation" with list of dictionaries assigning each translation to a language code. Example of such a json file for Polish language you may find here: inst/examples/data/translation.json.

How to contribute?

If you want to contribute to this project please submit a regular PR, once you're done with new feature or bug fix.

Changes in documentation

Both repository README.md file and an official documentation page are generated with Rmarkdown, so if there is a need to update them, please modify accordingly a README.Rmd file and run a build_readme.R script to compile it.

Troubleshooting

We used the latest versions of dependencies for this library, so please update your R environment before installation.

Future enhacements

  • Format numeric data
  • Support plural forms

Appsilon Data Science

Get in touch [email protected]

shiny.i18n's People

Contributors

dokato avatar krzyslom avatar marekrogala avatar jey1401 avatar fractalpolarity avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.