# prisma-selections

> Prisma selections allow you to define "select aliases", so instead of writing:

Latest version **0.0.4** (published 2023-01-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install prisma-selections
pnpm add prisma-selections
yarn add prisma-selections
bun add prisma-selections
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2023-01-15 |
| First published | 2023-01-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Dependencies | 1 |
| Unpacked size | 14.9 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Leon Si |
| Maintainers | leondreamed |

## Links

- npm: https://www.npmjs.com/package/prisma-selections
- Repository: https://github.com/leondreamed/prisma-selections
- Homepage: https://github.com/leondreamed/prisma-selections#readme
- Issues: https://github.com/leondreamed/prisma-selections/issues
- npm.io page: https://npm.io/package/prisma-selections

## Dependencies (1)

- [deepmerge-ts](https://npm.io/package/deepmerge-ts.md) ^4.2.2

## Recent versions

- 0.0.4 (latest) — 2023-01-15
- 0.0.3 — 2023-01-15
- 0.0.2 — 2023-01-15
- 0.0.1 — 2023-01-15

## README

# Prisma Selections

Prisma selections allow you to define "select aliases", so instead of writing:

```typescript
const user = await prisma.user.findUnique({
  select: {
    id: true,
    fullName: true,
    username: true,
    avatarUrl: true,
    // ...
  }
})
```

You can write this instead:

```typescript
const user = await prisma.user.findUnique({
  select: selections.user({
    $profileData: true,
    // ...
  })
})
```

And fully leverage the powerful intellisense provided by Prisma's TypeScript types!

---
_Source: https://npm.io/package/prisma-selections · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
