Giter Club home page Giter Club logo

scaffolder's Introduction

Laravel scaffolder

Scaffolder for laravel Software license Laravel version Waffle board Gitter chat

Remove the headache of creating over and over again the base code for most of your projects. You are free to extend it the way you need. This package only generate things that you need to start, always keeping the code clean and abstract. Are you hungry ? Fork it !

Installation

  1. Get laravel up and running

  2. Add the following packages to your composer.json

    ...
    "laravelcollective/html": "5.2.*",
    "yajra/laravel-datatables-oracle": "~6.0",
    "mpaleo/view-tags": "~1.0",
    "mpaleo/scaffolder-theme-material": "~1.0",
    "mpaleo/scaffolder": "~2.0",
    ...
  3. Update your packages

    composer update
  4. Add the service providers to the providers array in {laravel-root}\config\app.php

    ...
    ViewTags\ViewTagsServiceProvider::class,
    ScaffolderTheme\ScaffolderThemeServiceProvider::class,
    Scaffolder\ScaffolderServiceProvider::class,
    Yajra\Datatables\DatatablesServiceProvider::class,
    ...
  5. Add the following aliases in {laravel-root}\config\app.php

    ...
    'ViewTags'   => ViewTags\ViewTags::class,
    'Form'       => Collective\Html\FormFacade::class,
    'Html'       => Collective\Html\HtmlFacade::class,
    ...

Getting started

First you need to publish the configuration files and assets

./artisan vendor:publish --provider="Scaffolder\ScaffolderServiceProvider"
./artisan vendor:publish --provider="ScaffolderTheme\ScaffolderThemeServiceProvider" --force

Here we are using the theme mpaleo/scaffolder-theme-material, but you can fork it, and do whatever you want/need :)

At this point, you already can start to scaffold things. You have two ways to use the package.

Command line way

When you execute the artisan publish command, the service provider creates the folder {laravel-root}\scaffolder-config that has the following structure:

- scaffolder-config
-- app.json
-- models
-- cache

The app.json file contains global settings, also you will get some demo files for models. All you need to scaffold an application is to edit the app.json file, and create the json files for the models you want. After you have all the files ready, you have the following commands:

This command generate the application using the files that you have provided.

./artisan scaffolder:generate

For instance, when you update the package, you should clear the cache files stored in {laravel-root}\scaffolder-config\cache

./artisan scaffolder:cache-clear
User interface way

All you need to do, is go to your http://{crazyhost}/scaffolder/generator and fill some inputs :)

Next steps

Contributing

Just let me know your ideas and let's work together

Coding style

It would be great if we follow the PSR-2 coding standard and the PSR-4 autoloading standard.

License

The scaffolder package is licensed under the MIT license

scaffolder's People

Contributors

mpaleo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

scaffolder's Issues

Having issues with the datatable.

* DataTables warning: table id=DataTables_Table_0 - Ajax Error*

Do we need to run a artisan command to create the initial datatable or have you looked into this at all?

do you have skype and if so will you tell me the id so we can work together like you say on your homepage.

thanks

Testing

It would be cool to use materialize toasts with undo button

Validations

Add validations to generator UI and backend

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.