Skip to content

[Feature]: Add a flag to declare model timestamps as not nullable #84

@joelstein

Description

@joelstein

What happened?

First of all, thanks for this excellent package. Also, I couldn't figure out how to request a feature, so this is coming through as a bug report. Sorry!

Laravel's model timestamps always makes created_at and updated_at nullable (here's why).

This causes the types to be like:

created_at?: string
updated_at?: string

Even though they will always have a value.

Would you consider adding a config option to force model timestamps always to be strings instead of nullable strings?

How to reproduce the bug

(The bug report form requires me to put something here...)

Package Version

3.1

PHP Version

8.3.13

Which operating systems does with happen with?

macOS

Notes

No response

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions