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

Shorten/simplify client type signature for readability #5021

Closed
schickling opened this issue Jan 28, 2020 · 2 comments
Closed

Shorten/simplify client type signature for readability #5021

schickling opened this issue Jan 28, 2020 · 2 comments
Labels
domain/client Issue in the "Client" domain: Prisma Client, Prisma Studio etc. kind/improvement An improvement to existing feature and code.

Comments

@schickling
Copy link
Member

The Prisma Client for JS/TS provides an extremely powerful type-safe API which enables a great developer experience and robust applications. However, there's also currently a flip-side to this which is that the way the type signature (for most operations) is constructed/formatted makes the API type signature quite "intimidating" and hard to read. Additionally it also massively reduces the visible space for our generated JSDocs to be displayed in editors (e.g. VSCode) as seen here:

image

I'd love to explore whether there are "better" ways (i.e. simpler/less characters) for us to layout the type signature (e.g. by using type aliases).

@divyenduz
Copy link
Contributor

Internal note: dropping from current sprint

@pantharshit00 pantharshit00 transferred this issue from prisma/prisma-client-js Jan 13, 2021
@pantharshit00 pantharshit00 added kind/improvement An improvement to existing feature and code. domain/client Issue in the "Client" domain: Prisma Client, Prisma Studio etc. labels Jan 13, 2021
@pantharshit00
Copy link
Contributor

It is much simpler now as return type is properly resolved now.

image

I am going to close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain/client Issue in the "Client" domain: Prisma Client, Prisma Studio etc. kind/improvement An improvement to existing feature and code.
Projects
None yet
Development

No branches or pull requests

3 participants