names

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ColumnBaseGoType

func ColumnBaseGoType(col *schema.Column) string

ColumnBaseGoType returns the non-nullable Go type for a column.

func ColumnGoType

func ColumnGoType(col *schema.Column) string

ColumnGoType returns the Go type string for a column.

func ColumnImport

func ColumnImport(col *schema.Column) string

ColumnImport returns the import path needed for a column's Go type.

func PascalToSnake

func PascalToSnake(s string) string

PascalToSnake converts PascalCase to snake_case. UserController → user_controller, CreateUser → create_user, HTTPServer → http_server.

func Pluralize

func Pluralize(s string) string

Pluralize converts a singular lowercase word to its plural form. Handles common irregular plurals and English pluralization rules.

func SnakeToPascal

func SnakeToPascal(s string) string

SnakeToPascal converts snake_case to PascalCase, respecting common initialisms.

func TableToStructName

func TableToStructName(name string) string

TableToStructName converts a table name to a singular PascalCase Go struct name.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL