Skip to content

typescript re-write#57

Open
mmkal wants to merge 4 commits intof:masterfrom
mmkal:ts
Open

typescript re-write#57
mmkal wants to merge 4 commits intof:masterfrom
mmkal:ts

Conversation

@mmkal
Copy link

@mmkal mmkal commented Mar 14, 2025

Fixes #56

This replaces coffee/omelette.coffee with typescript/omelette.ts

Some notes:

Stuff I didn't change:

  • any CI workflows (I noticed there are both github actions and travis)
  • didn't remove the src/omelette.js folder, even though it's generated from typescript/omelette.ts - keeping under source control is somewhat unconventional but it's equivalent to how it was with Coffeescript
  • didn't aim to improve any implementations or type definitions along the way - thought there'd be more value in a port that matches the published version as closely as possible
  • any consolidation with deno
  • any file/folder organization patterns. It's somewhat unusual to have the compiled output live in src/, usually that would be for the "source" code (typescript/coffee), and the output would be in dist/ or lib/. But not a big deal so I left it.

Any/all of those could come after, but I don't see them as problems per se - esp if updates to this repo aren't too frequent and releases are manual.

Review notes:

  • it might be better to look at the diff to src/omelette.js rather than typescript/omelette.ts (you'll need to "show large diffs" and will want to ignore whitespace changes if viewing on github)

Testing:

  • autocompletion is obviously v hard to test on a CI runner, but I tried it out by linking locally to my trpc-cli which uses omelette to add completions to a CLI built from a trpc router (commander instance under the hood). Types and runtime look good, but again help testing would be great!

@mmkal
Copy link
Author

mmkal commented Mar 31, 2025

@f what do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert to typescript?

1 participant