Skip to content

Makaroni-Framework/Makaroni

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Makaroni

Makaroni is an yummy framework made for PHP developers ;))

Features

  • Simple and easy to use
  • Routing system
  • Validation
  • QueryBuilder
  • Migration

Requirements

PHP >= 8

Getting Started

via Composer:

composer create-project makaroni/framework project-name

OR

download last release and run composer install.

Now start the magic!

*NOTE: To see an example of a blog application, go to the blog branch.

Directory trees

  • img : have makaroni logo image
  • main : this directory have your application codes
    • config : there are config.php file for config your app
    • public : index.php directory
    • route : define your routes in route.php
    • System : directory for controllers and models (write your helper methods in helpers.php)
    • view : create your views here
    • Migration : write your migrations here

Routing

See full documentation

Validation

You can validate your inputs with validate method, which gives array of arrays for validation:

use Makaroni\Framework\Validation\Validation;

class PostController
{
    public function store()
    {
        $title = request()->input('title');

        (new Validation)->validate([
            ['title', $title, 'words'],
        ]);

        // continues if inputs are valid
    }
}

QueryBuilder

See full documentation

Migration

See full documentation

Yum

Use yum for run your local webserver:

php yum

// PHP Development Server (http://localhost:8080) started...

Migrate

Use migrate for run your migrations

php migrate

Contributing

Send your pull requests for contributing.

License

MIT.