HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
sefaira
rho-contracts.js
HISTORICAL RECORD2013–2017
sefaira / rho-contracts.js · Not publicly available

rho-contracts.js

Discover this repository through its Hacker News conversations.

3Distinct people
3Mentions
0Explicit recommenders
REPOSITORY AT A GLANCE

What to know before exploring

What it is

A public description has not been verified.

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 5:04:57 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year3 dated mentions

Observed mentions: 2013-05-20 15:53:03 UTC to 2017-06-13 16:42:02 UTC.

012013-01-01 00:00:00 UTC to 2014-01-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments20132014-01-01 00:00:00 UTC to 2015-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2015-01-01 00:00:00 UTC to 2016-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments20152016-01-01 00:00:00 UTC to 2017-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2017

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20132013-01-01 00:00:00 UTC2014-01-01 00:00:00 UTC110
20142014-01-01 00:00:00 UTC2015-01-01 00:00:00 UTC101
20152015-01-01 00:00:00 UTC2016-01-01 00:00:00 UTC000
20162016-01-01 00:00:00 UTC2017-01-01 00:00:00 UTC000
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC101

What Hacker News says

3 sources
Why not use type annotations to accomplish this? Do we really need another compile to JavaScript language for something that did not require changing the language syntax? There is no reason that a similar project could not have been made via smaller modules using comment annotations. This project really should be at least two projets: (1) one npm module for parsing the type signatures with the line numbers of the functions it applies to. (2) one module that takes in that intermediary representation and performs the AST transform for wrapping the functions. I don't see why this couldn't have been accomplished with: (1) the doctrine module [0] for parsing JSDoc comment blocks before functions OR a custom module for recognizing a custom comment delimiter like //+ or //! followed by the type annotation such as Haskell's type d
Read the rest
eclaration format. (2) a module for parsing closure compiler JSDoc type signatures (3) the racket-style higher order contracts module [1] for a way to do run-time checking (3) a module consisting of all the possible permutations of higher order type checking functions based on rho-contracts (4) the node-falafel module [2] for performing the actual AST transform that wraps those contract functions around the function described by the JSdoc comment. Furthermore, this approach of breaking this up in to modules allows multiple people to propose alternative syntaxes for this for consideration in future versions of ECMAScript. I wouldn't be surprised if sweet.js could also be used for those syntax approaches that go beyond comment-based annotations and involve modifying the syntax of the language itself. For those that built this at Google, please please please consider breaking this down into smaller composable modules. I'd love to be able to play with the subcomponents of this myself without having to adopt yet another language that doesn't parse with off the shelf tools [4]. [0] https://github.com/Constellation/doctrine [1] https://github.com/sefaira/rho-contracts.js [2] https://github.com/substack/node-falafel [3] http://sweetjs.org/ [4] See JSX for the clusterfuck[6] that results when you add yet another format that needs to be parsed in a unique way with no real benefit that couldn't be accomplished just as easily without fucking with the standard language syntax. See Wadler's Law [5] [5] http://www.haskell.org/haskellwiki/Wadler's_Law [6] https://www.npmjs.org/package/esprima-fb
In AtScript Primer

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.