Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dutchcodingcompany/laravel-notes
https://github.com/dutchcodingcompany/laravel-notes
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/dutchcodingcompany/laravel-notes
- Owner: DutchCodingCompany
- License: mit
- Created: 2021-01-14T09:56:51.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-02-21T14:07:28.000Z (almost 3 years ago)
- Last Synced: 2024-06-11T20:27:45.270Z (6 months ago)
- Language: PHP
- Size: 5.86 KB
- Stars: 1
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Laravel Notes
## Installation
You can install the package via composer:
```
composer require dutchcodingcompany/laravel-notes
```Then publish the package migrations, configuration files and resources.
```
php artisan vendor:publish --provider=DutchCodingCompany\Notes\NoteServiceProvider
```Then execute the migrations.
```
php artisan migrate
```## Configuration
You may change the note model that is used by changing the `table` or `model` in the `notes.php` config.
```
'table' => 'notes','model' => \App\Models\Note::class,
```## Usage
Add the `HasNotes` interface and trait to the model.
```php
use DutchCodingCompany\Notes\Concerns\HasNotes;
use DutchCodingCompany\Notes\Contracts\HasNotes as HasNotesContract;class Post extends Model implements HasNotesContract
{
use HasNotes;
// ...
}
```## Credits
- [Bjorn Voesten](https://github.com/bjornvoesten)
- [Dutch Coding Company](https://github.com/dutchcodingcompany)
- [All contributors](https://github.com/dutchcodingcompany/csv-collection/graphs/contributors)## License
The MIT License (MIT). Please see [License File](LICENSE.md) for more information.