npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@vertexa/prisma

v7.9.1

Published

Fork of Prisma ORM CLI with PostGIS support — database toolkit with schema migrations, code generation, and type-safe queries for PostgreSQL, MySQL, SQLite, SQL Server, and MongoDB. Adds native Geometry/Geography scalar types and spatial filters (near, wi

Downloads

221

Readme

@vertexa/prisma

Fork of Prisma ORM with PostGIS / Geometry support for PostgreSQL.

What is this?

This is a rebranded fork of Prisma ORM v7.8, published under the @vertexa npm scope. The fork adds native PostGIS support — schema-level Geometry / Geography scalar types, query filters (near, within, intersects), and GeoJSON ↔ EWKB serialization — on top of the standard Prisma feature set.

Everything else works the same as upstream Prisma. If you know Prisma, you know this fork.

Why this fork exists

Install

npm install @vertexa/prisma @vertexa/prisma-client

With pnpm, add an override so internal deps resolve to the fork:

{
  "pnpm": {
    "overrides": {
      "@vertexa/prisma-debug": "npm:@vertexa/[email protected]",
    },
  },
}

Usage

npx @vertexa/prisma generate
npx @vertexa/prisma db push
npx @vertexa/prisma migrate dev

PostGIS schema

generator client {
  provider = "prisma-client-js"
}

datasource db {
  provider = "postgresql"
}

model Location {
  id       Int        @id @default(autoincrement())
  name     String
  position Geography? @db.Geography(Point, 4326)
}

model Area {
  id       Int       @id @default(autoincrement())
  name     String
  boundary Geometry? @db.Geometry(Polygon, 4326)
}

PostGIS queries

import { PrismaClient } from '@vertexa/prisma-client'
import { PrismaPg } from '@vertexa/prisma-adapter-pg'
import { Pool } from 'pg'

const prisma = new PrismaClient({ adapter: new PrismaPg(new Pool({ connectionString: process.env.DATABASE_URL })) })

// near → ST_DWithin
await prisma.location.findMany({
  where: { position: { near: { point: [2.35, 48.85], distance: 1000 } } },
})

// intersects → ST_Intersects
await prisma.area.findMany({
  where: {
    boundary: {
      intersects: {
        geometry: {
          type: 'Polygon',
          coordinates: [
            [
              [1, 1],
              [1, 3],
              [3, 3],
              [3, 1],
              [1, 1],
            ],
          ],
        },
      },
    },
  },
})

// orderBy distanceFrom → ST_Distance
await prisma.location.findMany({ orderBy: { position: { distanceFrom: [2.35, 48.85] } } })

PostGIS features

| Feature | SQL | Schema type | | ---------------------------- | --------------- | -------------------------- | | near filter | ST_DWithin | Geography | | within filter | ST_Within | Geometry | | intersects filter | ST_Intersects | Geometry | | distanceFrom orderBy | ST_Distance | Geography / Geometry | | GeoJSON ↔ EWKB round-trip | — | Geometry / Geography | | Multi-SRID (4326, 3857, ...) | — | @db.Geometry(type, srid) |

Packages

This CLI is part of a fork that publishes these packages under @vertexa/*:

| Package | Replaces | | -------------------------------------- | ------------------------------ | | @vertexa/prisma | prisma | | @vertexa/prisma-client | @vertexa/prisma-client | | @vertexa/prisma-adapter-pg | @vertexa/prisma-adapter-pg | | @vertexa/prisma-config | @vertexa/prisma-config | | @vertexa/prisma-driver-adapter-utils | @vertexa/prisma-driver-adapter-utils | | @vertexa/prisma-debug | @vertexa/prisma-debug | | @vertexa/prisma-engines | @vertexa/prisma-engines | | @vertexa/prisma-engines-version | @vertexa/prisma-engines-version | | @vertexa/prisma-fetch-engine | @vertexa/prisma-fetch-engine | | @vertexa/prisma-get-platform | @vertexa/prisma-get-platform | | @vertexa/prisma-client-runtime-utils | @vertexa/prisma-client-runtime-utils | | @vertexa/prisma-query-compiler-wasm | @vertexa/prisma-query-compiler-wasm | | @vertexa/prisma-schema-engine-wasm | @vertexa/prisma-schema-engine-wasm | | @vertexa/prisma-prisma-schema-wasm | @vertexa/prisma-schema-wasm |

License

Apache-2.0