Giter Club home page Giter Club logo

Comments (4)

JonasWanke avatar JonasWanke commented on June 2, 2024

time_machine is used internally for all date & time formatting. By default, it uses en_US as its locale (managed by the Culture class) and doesn't know about Flutter's locale. To change it to French, set Culture.current after the call to TimeMachine.initialize:

await TimeMachine.initialize({'rootBundle': rootBundle});
// Supported cultures: https://github.com/Dana-Ferguson/time_machine/tree/master/lib/data/cultures
Culture.current = await Cultures.getCulture('fr');
runApp(/* ... */);

There's an open issue for time_machine to provide a LocalizationsDelegate for easier integration: Dana-Ferguson/time_machine#28

from timetable.

joj3000 avatar joj3000 commented on June 2, 2024

Great, thank you very much !

from timetable.

JulianKowalczuk avatar JulianKowalczuk commented on June 2, 2024

@JonasWanke, could You put this info in readme? Some newbies won't dig in PRs to find out that and this is probably why flutter_week_view package is more popular, even I think Your one is better.

from timetable.

JonasWanke avatar JonasWanke commented on June 2, 2024

@JulianKowalczuk Thanks! I've just published v0.2.5 and added a Localization section to the README.

I'll still leave this issue open as I want to simplify this soon.

from timetable.

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.