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

3.0.0 #101

Open
haltcase opened this issue Jun 1, 2020 · 4 comments
Open

3.0.0 #101

haltcase opened this issue Jun 1, 2020 · 4 comments
Labels
discussion [RFC] Fixes, APIs, or changes need feedback.
Milestone

Comments

@haltcase
Copy link
Owner

haltcase commented Jun 1, 2020

I've started thinking about any breaking changes I'd like to make for the v3 release. So far they're pretty much all type related and serve to either improve inference or make something stricter, which is an evolution of v2's rewrite to TypeScript.

  • eliminate (or drastically reduce the size of) the Trilogy class
    • basically all it does is duplicate methods on Model instances, but with worse capability for type inference and is therefore less safe
  • remove dot-delimited strings in favor of explicitly passing the model & column names separately
  • improve type inference, particularly for models by using the provided schemas
  • make types stricter where possible
@haltcase haltcase added the discussion [RFC] Fixes, APIs, or changes need feedback. label Jun 1, 2020
@haltcase haltcase added this to the v3.0.0 milestone Jun 1, 2020
@vazra
Copy link

vazra commented Jun 20, 2020

@citycide when are you planning to release v3?

@haltcase
Copy link
Owner Author

@citycide when are you planning to release v3?

Right now I'm only in the brainstorm stage, so these changes haven't begun yet. I just wanted to let people know what I'm thinking about doing for the next version to get feedback and guide contributions.

@vazra
Copy link

vazra commented Jun 20, 2020

okay cool!

@haltcase
Copy link
Owner Author

I have a branch open for this at v3 and have made some progress but there's a fair amount of work left. I've got pretty intelligent type inference that's frustratingly close to working how I want it, but still has some issues with nullability. There's also a lot of any casting and such going on at the moment which I'd like to clean up at some point.

There are also a lot of comments asking for this TypeScript PR because I have to do things like this all over the place (lots of generics):

https://github.com/citycide/trilogy/blob/fe90ddf72942a8339c10dace20caf70615498c0e/src/model.ts#L48

I'd appreciate any help on getting this moving — I've been beating my head against it for a while!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion [RFC] Fixes, APIs, or changes need feedback.
Projects
None yet
Development

No branches or pull requests

2 participants