Giter Club home page Giter Club logo

Comments (5)

thekip avatar thekip commented on May 23, 2024 1

You can contribute, we will happily accept PRs

from js-lingui.

andrii-bodnar avatar andrii-bodnar commented on May 23, 2024 1

@aseerkt yes, we'd be happy to accept a PR

from js-lingui.

vonovak avatar vonovak commented on May 23, 2024

This way I could load the compiled messages without needing to interpret javascript code.

would you mind expanding on why you want this?

Please note that even the JS files are currently just export const messages = JSON.parse(...)

Thank you :)

from js-lingui.

simlmx avatar simlmx commented on May 23, 2024

@vonovak

would you mind expanding on why you want this?

I have a pretty complex setup where other packages (other than the one in which the translations are compiled) need to consume the compiled message files, and it made my life easier if they are simply in JSON.

But since then I managed to make it work with compiled .mjs files!

Please note that even the JS files are currently just export const messages = JSON.parse(...)

Yes I saw that! Any reason to not use the JSON files by default and save a couple of characters? It would make the compiled files easy to load anywhere (for instance in a python backend or I don't know).

from js-lingui.

aseerkt avatar aseerkt commented on May 23, 2024

Can I raise a PR for this? @simlmx @andrii-bodnar 👀

from js-lingui.

Related Issues (20)

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.