Default to UUID orimary key via app settings

I asked about this years ago, and I see it’s possible to use a UUID as the primary key, but I’d like to propose we add an app setting to .hanamirc that will default primary keys in generated migrations to UUID. If it’s not amenable to support a UUID type or a :uuid column type w/o the call to Hanami::Model::Sql.function(:uuid_generate_v4) then I think it would at least be a better dev experience to inject that when generating the migration.

Thoughts?

1 Like