In 3.0, we made the decision to export all types from the main package export (e.g. `payload/types` => `payload`). This improves type discoverability by IDEs and simplifies importing types. This PR does the same for our db adapters, which still have a separate `/types` subpath export. While those are kept for backwards-compatibility, we can remove them in 4.0.
Payload Postgres Adapter
Official Postgres adapter for Payload.
Installation
npm install @payloadcms/db-postgres
Usage
import { buildConfig } from 'payload'
import { postgresAdapter } from '@payloadcms/db-postgres'
export default buildConfig({
db: postgresAdapter({
pool: {
connectionString: process.env.DATABASE_URI,
},
}),
// ...rest of config
})
More detailed usage can be found in the Payload Docs.