A few words on Ruby's type annotations state

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • contracts.ruby

    Contracts for Ruby.

  • I had written a code contracts library for Ruby about 10 years ago [1]. I stopped working on it, mainly because it only provided runtime type checking, and I wanted static type checking. Nowadays my main language is typescript. I miss ruby, but can't give up the static typing that typescript provides. I really wish Ruby had a type system with the same level of support. VSCode has phenomenal TS support, and there's a community adding types to projects [2]. This is something I'd like for Ruby also.

    > An integral part of this informality is relying on Matz’s taste and intuition for everything that affects the language’s core.

    I think a more defined process would mean a better future for Ruby and Ruby developers.

    - [1] https://github.com/egonschiele/contracts.ruby

    - [2] https://github.com/DefinitelyTyped/DefinitelyTyped

  • sorbet

    A fast, powerful type checker designed for Ruby

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • dd-trace-rb

    Datadog Tracing Ruby Client

  • > For myself, I'm fine with the typing being in a separate .rbs file

    We type[0] by having one separate .rbs file per .rb file. Works really well with an editor's vertical splits: type outline on one side, code on the other. That, or use something like vim-projectionist[1].

    [0]: (WIP: there's a huge codebase to type, but we're progressively getting there) https://github.com/DataDog/dd-trace-rb/tree/master/sig

    [1]: https://github.com/tpope/vim-projectionist

  • vim-projectionist

    projectionist.vim: Granular project configuration

  • > For myself, I'm fine with the typing being in a separate .rbs file

    We type[0] by having one separate .rbs file per .rb file. Works really well with an editor's vertical splits: type outline on one side, code on the other. That, or use something like vim-projectionist[1].

    [0]: (WIP: there's a huge codebase to type, but we're progressively getting there) https://github.com/DataDog/dd-trace-rb/tree/master/sig

    [1]: https://github.com/tpope/vim-projectionist

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts