JSMonk / hegel

An advanced static type checker
https://hegel.js.org
MIT License
2.09k stars 59 forks source link

Project status #363

Open kee-oth opened 2 years ago

kee-oth commented 2 years ago

Hi!

I found Hegel in my search for a TypeScript alternative that is more friendly for functional programming. I also love that I can define functions in this format:

const add
    : number => number => number
    = x => y => x + y

Defining types outside of the function definition really helps with readability for me and also type portability within a project. It's actually really difficult to find something suitable for web development that allows this format. It seems that it's mainly just ML inspired functional languages allow this which is a shame.

TypeScript's version is noisy and couples the parameter names with the type causing redundancy:

const add
    : (x: number) => (y: number) => number
    = x => y => x + y

ReScript allows this but has a strict auto-formatter that would collapse my desired format to:

const add : number => number => number = x => y => x + y

Which completely undermines the readability of pulling the types out.

Elm interop with JS is difficult and the future of the language is uncertain.

So that leaves Hegel at the moment. This leaves me with the question of: is Hegel still being maintained or supported? I'd really like to use it but it looks like the repo doesn't have much going on and the last Twitter post is from early 2021.

Is Hegel still planning on being maintained or is this project abandoned?

Thanks!

thecotne commented 2 years ago

TypeScript alternative that is more friendly for functional programming

there are bunch of those

I also love that I can define functions in this format:

flow has same syntax but it has been half dead for a long time now

it is supported and maintained but it is lagging behind compared to typescript and all major projects are dropping flow and moving to typescript

currently only facebook is using flow in it's products and even they decided to not use flow in some of their open source projects

is Hegel still being maintained or supported?

current version is abandoned but there is a hope that some day we may get new one ...

it was mentioned few times that typescript's syntax is used for new version so if syntax is the main concern then next hegel wont solve your problems

gaeulbyul commented 2 years ago

unfortunately, I suspended the work on Hegel in a period of the war in Ukraine to focus on help to my parents and friends in Kharkiv/Kyiv.

https://github.com/JSMonk/hegel/issues/355#issuecomment-1075389775