Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/svycal/zonex
An Elixir library for compiling enriched time zone information
https://github.com/svycal/zonex
elixir time-zones
Last synced: about 1 month ago
JSON representation
An Elixir library for compiling enriched time zone information
- Host: GitHub
- URL: https://github.com/svycal/zonex
- Owner: svycal
- License: other
- Created: 2022-07-22T20:47:18.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-06-20T15:32:58.000Z (over 1 year ago)
- Last Synced: 2024-09-17T08:27:49.645Z (4 months ago)
- Topics: elixir, time-zones
- Language: Elixir
- Homepage: https://hexdocs.pm/zonex
- Size: 126 KB
- Stars: 9
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Zonex [![Hex Docs](https://img.shields.io/hexpm/v/zonex)](https://hexdocs.pm/zonex/readme.html)
An Elixir library for compiling enriched time zone information.
## Installation
Add `zonex` to your list of dependencies in `mix.exs`. You will also need to install and configure the `ex_cldr` library with the `ex_cldr_time_zone_names` plugin, since Zonex requires a CLDR backend for compiling time zone names.
```elixir
def deps do
[
{:zonex, "~> 0.6.0"},# Additional required dependencies
{:ex_cldr, "~> 2.33"},
{:ex_cldr_time_zone_names, "~> 0.1"},# ...
]
end
```In your application, configure your CLDR backend module:
```elixir
defmodule MyApp.Cldr do
use Cldr,
providers: [
Cldr.TimeZoneNames,
# ...
],
# ...
end
```Then, let Zonex know what CLDR backend module to use in your application config:
```elixir
# config/config.exsconfig :zonex, cldr_backend: MyApp.Cldr
```