# Elm-unicode is here!

**URL:** <https://discourse.elm-lang.org/t/elm-unicode-is-here/7149>\
**Category:** Show and Tell\
**Created:** [March 24, 2021, 10:35pm UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149 "2021-03-24T22:35:42Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![miniBill](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/minibill/32/800_2.png) [@miniBill](https://discourse.elm-lang.org/u/miniBill)\
**Post date:** [March 24, 2021, 10:35pm UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/1 "2021-03-24T22:35:42Z")

</div>

I’ve recently published [elm-unicode](https://package.elm-lang.org/packages/miniBill/elm-unicode/latest/). It is basically a Unicode version of the `Char.isXYZ` functions. I’m sorry the documentation is a bit sparse but… I really didn’t know what more to say.

This solves the problem that `Char.isLower 'α'` or `Char.isLower 'è'` are both `False`.

It is automatically generated based on the latest Unicode standard which, at the time of writing, is Unicode 13.

Feel free to give feedback or ask questions!.

---

<div class="post-metadata">

**Author:** ![NiavlysB](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/niavlysb/32/3570_2.png) [@NiavlysB](https://discourse.elm-lang.org/u/NiavlysB)\
**Post date:** [March 28, 2021, 9:56pm UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/2 "2021-03-28T21:56:46Z")

</div>

Nice! Do you plan on adding more features or just keeping it a Unicode-aware version of Char?  
I’m working on an app in which I will need to be able to get the Unicode name of a specific codepoint for instance. Some more ideas that would potentially be useful:

- Unicode normalization
- planes and blocks names
- HTML entity representations

EDIT: In any case, thank you for this example of code generation from the Unicode standard, I might use that as a guide for the use case I mentioned!

---

<div class="post-metadata">

**Author:** ![miniBill](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/minibill/32/800_2.png) [@miniBill](https://discourse.elm-lang.org/u/miniBill)\
**Post date:** [March 29, 2021, 12:27am UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/3 "2021-03-29T00:27:11Z")

</div>

I’m open to adding new features, but only if “`Char`-level”. For graphemes and stuff there should be other libraries imo.

Your three ideas are interesting and respectively: very hard and probably out of scope, feasible and in scope (open an issue on the repo) and trivial (just use Char.toCode, elm-hex and some string concat) and probably out of scope

---

<div class="post-metadata">

**Author:** ![NiavlysB](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/niavlysb/32/3570_2.png) [@NiavlysB](https://discourse.elm-lang.org/u/NiavlysB)\
**Post date:** [March 29, 2021, 8:45am UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/4 "2021-03-29T08:45:58Z")

</div>

That’s fair!  
I’m realizing as well that the normalization stuff would be at `String` level, since it’s about turning two characters into one, among other things.  
What about getting the Unicode name from the character? I’m guessing it’s probably not useful to a lot of people and it might lead to a big file size maybe?

---

<div class="post-metadata">

**Author:** ![miniBill](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/minibill/32/800_2.png) [@miniBill](https://discourse.elm-lang.org/u/miniBill)\
**Post date:** [March 29, 2021, 9:11am UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/5 "2021-03-29T09:11:51Z")

</div>

It would lead to a big size, yes, although it’s also true that dead code elimination would strip it out for people who don’t need it. At the same time I think that it’s probably uncommon and it shouldn’t be hard for people who need it to just vendor my code

---

<div class="post-metadata">

**Author:** ![NiavlysB](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/niavlysb/32/3570_2.png) [@NiavlysB](https://discourse.elm-lang.org/u/NiavlysB)\
**Post date:** [March 29, 2021, 9:29am UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/6 "2021-03-29T09:29:08Z")

</div>

I didn’t think about dead code elimination. But yes it’s probably uncommon, and yes I will probably get inspiration from your code in my case!

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex035/uploads/elm_lang/original/1X/50a05e53677a2c3b47776d7abd0f113eb50193a1.png) [@system](https://discourse.elm-lang.org/u/system)\
**Post date:** [April 8, 2021, 9:29am UTC](https://discourse.elm-lang.org/t/elm-unicode-is-here/7149/7 "2021-04-08T09:29:49Z")

</div>

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.
