We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1147936 commit bfa6828Copy full SHA for bfa6828
CHANGELOG.md
@@ -0,0 +1,13 @@
1
+# Unreleased
2
+
3
+# v.1.1
4
5
+**Release date**: 2023-04-30
6
7
+- HasNew: Returns a new instance of the class that uses the trait.
8
9
+# v1.0
10
11
+**Release date**: 2023-03-28
12
13
+- HasPrefix trait. Use it to add a prefix to tables.
src/Contracts/HasNew.php
@@ -0,0 +1,14 @@
+<?php
+namespace Illegal\LaravelUtils\Contracts;
+trait HasNew
+{
+ /**
+ * Return a new instance of the class
+ */
+ public static function new(): self
+ {
+ return new static();
+ }
14
+}
0 commit comments