All Projects → baptiste0928 → rosetta

baptiste0928 / rosetta

Licence: ISC license
Easy to use Rust i18n library based on code generation

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to rosetta

graphql-ts-client
Typescript DSL for GraphQL.
Stars: ✭ 124 (+235.14%)
Mutual labels:  codegen
Slim-Auth
A Slim 4 Skeleton.
Stars: ✭ 22 (-40.54%)
Mutual labels:  i18n
Kotsu
✨ Clean, opinionated foundation for new projects — to boldly go where no man has gone before
Stars: ✭ 48 (+29.73%)
Mutual labels:  i18n
qiokian
🙊 live2d anime waifu vuejs component.
Stars: ✭ 34 (-8.11%)
Mutual labels:  i18n
redux-polyglot
Polyglot.js bindings for Redux
Stars: ✭ 59 (+59.46%)
Mutual labels:  i18n
next.js-boilerplate
next.js bolierplate, next.js 的开发模板
Stars: ✭ 28 (-24.32%)
Mutual labels:  i18n
strf
Yet another C++ text formatting library.
Stars: ✭ 57 (+54.05%)
Mutual labels:  i18n
rails
Rails translation made _('simple').
Stars: ✭ 65 (+75.68%)
Mutual labels:  i18n
translation-generator
Generate translation files for your Angular project
Stars: ✭ 17 (-54.05%)
Mutual labels:  i18n
i18n-iso-languages
i18n for ISO 639-1 language codes
Stars: ✭ 38 (+2.7%)
Mutual labels:  i18n
bpmn-js-i18n
Internationalization resources for bpmn-js
Stars: ✭ 49 (+32.43%)
Mutual labels:  i18n
graphql-java-codegen-gradle-plugin
Gradle plugin for graphql-java-codegen
Stars: ✭ 19 (-48.65%)
Mutual labels:  codegen
ember-i18n-cp-validations
ember-i18n support for ember-cp-validations
Stars: ✭ 20 (-45.95%)
Mutual labels:  i18n
angular-i18n-localization
An angular application with i18n and localization implemented.
Stars: ✭ 22 (-40.54%)
Mutual labels:  i18n
github-explorer
Explore GitHub repositories - built with React.js and Styled Components.
Stars: ✭ 32 (-13.51%)
Mutual labels:  i18n
msgtools
Tools for Developing Diagnostic Messages
Stars: ✭ 18 (-51.35%)
Mutual labels:  i18n
deepl-php-lib
🧠 DeepL API Client Library supporting PHP >= 7.3
Stars: ✭ 50 (+35.14%)
Mutual labels:  i18n
i18n lazy scope
Use lazy lookup with custom i18n scopes.
Stars: ✭ 11 (-70.27%)
Mutual labels:  i18n
i18n-language.js
i18n-language.js is Simple i18n language with Vanilla Javascript
Stars: ✭ 21 (-43.24%)
Mutual labels:  i18n
express-mvp
Express.js project template ready to go
Stars: ✭ 21 (-43.24%)
Mutual labels:  i18n

rosetta-i18n

Crates.io dependency status docs.rs CI

rosetta-i18n is an easy-to-use and opinionated Rust internationalization (i18n) library powered by code generation.

rosetta_i18n::include_translations!();

println!(Lang::En.hello("world"));  // Hello, world!

Documentation

Features

  • No runtime errors. Translation files are parsed at build time, so your code will never fail due to translations anymore.
  • No dependencies. This crate aims to have the smallest runtime overheat compared to raw strings. There is no additional dependencies at runtime.
  • Standard JSON format. Translations are written in JSON file with a syntax used by many other i18n libraries. Therefore, most translation services support it out of the box.
  • String formatting is supported.

Installation

Rosetta is separated into two crates, rosetta-i18n and rosetta-build. To install both, add the following to your Cargo.toml:

[dependencies]
rosetta-i18n = "0.1"

[build-dependencies]
rosetta-build = "0.1"

Documentation

The documentation is available on https://baptiste0928.github.io/rosetta/.

You can also read the API documentation on docs.rs: rosetta-i18n and rosetta-build.

Contributing

There is no particular contribution guidelines, feel free to open a new PR to improve the code. If you want to introduce a new feature, please create an issue before.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].