Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(typegen): Go Type Gen #687

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

isaacharrisholt
Copy link
Contributor

@isaacharrisholt isaacharrisholt commented Jan 10, 2024

What kind of change does this PR introduce?

Feature

What is the current behaviour?

No Go types

What is the new behaviour?

This PR adds type generation for Go based on the proposal in this discussion.

There's also some cleanup in server.ts for local development, which a) crosses off a TODO comment and b) makes it simpler to extend with new type generators later.

Additional context

This PR requires #685 to be merged first and currently contains the changes from that PR. If you're interested in the changes made by this one, I recommend looking at commits b24e63d onwards, which mostly touch these files:

  • */go.ts
  • server.ts
  • routes.ts
  • package.json

Still TODO:

  • Handle composite types
  • Handle range types
  • Tests

Let me know your feedback or if you'd like any changes :)

@isaacharrisholt isaacharrisholt marked this pull request as ready for review January 11, 2024 19:18
@isaacharrisholt isaacharrisholt requested review from a team as code owners January 11, 2024 19:18
@isaacharrisholt isaacharrisholt changed the title DRAFT: feat(typegen): Go Type Gen feat(typegen): Go Type Gen Jan 11, 2024
@isaacharrisholt
Copy link
Contributor Author

Going to mark this as draft for now - I've decided it might be better to separate out the Select, Insert and Update models (as in JS) and make use of the sql.Null* types in the standard library

@isaacharrisholt
Copy link
Contributor Author

I've now done the above, so this should be ready to go

@isaacharrisholt isaacharrisholt marked this pull request as ready for review March 21, 2024 09:59
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.

None yet

1 participant