https://github.com/lassehaslev/laravel-package-template
Create a nice starter template for laravel package
https://github.com/lassehaslev/laravel-package-template
Last synced: 11 months ago
JSON representation
Create a nice starter template for laravel package
- Host: GitHub
- URL: https://github.com/lassehaslev/laravel-package-template
- Owner: LasseHaslev
- Created: 2017-03-27T21:37:24.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-02-09T07:32:56.000Z (over 8 years ago)
- Last Synced: 2025-02-05T16:04:27.203Z (over 1 year ago)
- Language: PHP
- Size: 18.6 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @lassehaslev/laravel-package-template
> Kickstarter for [Laravel package development](https://laravel.com/docs/5.4/packages)
## Install
```bash
npm install -g @lassehaslev/laravel-package-template
```
## Usage
```bash
# Go to the folder you want to create a package
# Option 1: Install all in current folder
laravel-package
# Option 2: Install in other folder
laravel-package my-new-package
# Follow instructions and you are good to go!
```
## Usage in Laravel application
> I use this package together with [LasseHaslev/laravel-modules](https://github.com/LasseHaslev/laravel-modules).
> Follow instructions to use with a laravel application.
1. Install package
`npm install @lassehaslev/laravel-package-template --save-dev`
2. Add script to project `package.json`
```json
{
"scripts": {
"package": "laravel-package"
}
}
```
3. Create package `npm run package Modules/page-name`
4. Run `composer dump-autoload`
5. Package is ready to use. **Happy Coding!**