Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
not-serializable
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
grifart libs
not-serializable
Commits
441847d8
Verified
Commit
441847d8
authored
3 years ago
by
Jan Kuchař
Browse files
Options
Downloads
Patches
Plain Diff
added docs
parent
4f541ef3
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+25
-0
25 additions, 0 deletions
README.md
docs/phpstorm-settings.png
+0
-0
0 additions, 0 deletions
docs/phpstorm-settings.png
with
25 additions
and
0 deletions
README.md
0 → 100644
+
25
−
0
View file @
441847d8
# Not serializable
As every object should be
`final`
as default. It should NOT be serializable as default.
Unfortunately reality in PHP is different.
If you want to make your classes NOT-serializable, you must explicitly state that.
# Usage
Require this package using composer
```
bash
composer require grifart/not-serializable
```
and update your IDE default class template to:
```
php
final
class
$
{
NAME
}
{
use
\Grifart\NotSerializable\NotSerializable
;
}
```

This diff is collapsed.
Click to expand it.
docs/phpstorm-settings.png
0 → 100644
+
0
−
0
View file @
441847d8
824 KiB
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment