Home / Function/ constructor() — drizzle-orm Function Reference

constructor() — drizzle-orm Function Reference

Architecture documentation for the constructor() function in custom.ts from the drizzle-orm codebase.

Entity Profile

Dependency Diagram

graph TD
  aa9ca753_b1b9_8365_a448_89581f60a5bb["constructor()"]
  e38b8925_0ba3_fff9_aafa_6a598e218292["PgCustomColumn"]
  aa9ca753_b1b9_8365_a448_89581f60a5bb -->|defined in| e38b8925_0ba3_fff9_aafa_6a598e218292
  bfab6770_6be8_71a7_94a6_83194b760394["constructor()"]
  bfab6770_6be8_71a7_94a6_83194b760394 -->|calls| aa9ca753_b1b9_8365_a448_89581f60a5bb
  bfab6770_6be8_71a7_94a6_83194b760394["constructor()"]
  aa9ca753_b1b9_8365_a448_89581f60a5bb -->|calls| bfab6770_6be8_71a7_94a6_83194b760394
  style aa9ca753_b1b9_8365_a448_89581f60a5bb fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

drizzle-orm/src/pg-core/columns/custom.ts lines 67–75

	constructor(
		table: AnyPgTable<{ name: T['tableName'] }>,
		config: PgCustomColumnBuilder<T>['config'],
	) {
		super(table, config);
		this.sqlName = config.customTypeParams.dataType(config.fieldConfig);
		this.mapTo = config.customTypeParams.toDriver;
		this.mapFrom = config.customTypeParams.fromDriver;
	}

Domain

Subdomains

Called By

Frequently Asked Questions

What does constructor() do?
constructor() is a function in the drizzle-orm codebase, defined in drizzle-orm/src/pg-core/columns/custom.ts.
Where is constructor() defined?
constructor() is defined in drizzle-orm/src/pg-core/columns/custom.ts at line 67.
What does constructor() call?
constructor() calls 1 function(s): constructor.
What calls constructor()?
constructor() is called by 1 function(s): constructor.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free