dhruv125/ownwork

OwnWork - Minimal PHP Framework for an MVC Project

Maintainers

Package info

github.com/Sanatani-Dhruv/ownwork

Type:project

pkg:composer/dhruv125/ownwork

Statistics

Installs: 18

Dependents: 0

Suggesters: 0

Stars: 1

Open Issues: 0

v1.0.4 2026-03-06 10:20 UTC

This package is not auto-updated.

Last update: 2026-04-03 10:39:58 UTC


README

Commits Last Commit Latest Release - Github Packagist Name Latest Release - Packagist Language Downloads Dependencies License

  • Don't go into major dependencies rabbit hole.
  • Build your MVC app with PHP.
  • Simple Routing.
  • Easier View Creation.
  • Build a Large Web App with minimal but useful base.

Dependencies

  1. php (version: 8.0 or greater).
  2. composer (version: 2.9 or greater).

Structure

ownwork
   ├── app
   │   ├── Controller # Your Controllers directory
   │   │   └── UserController.php
   │   ├── Helper # This file includes Helper and Support Files which handles important functions like Routing, Viewing
   │   │   ├── AppViews # Views Required by OwnWork like Error Pages
   │   │   │   ├── general-notfound-error.php
   │   │   │   ├── styles
   │   │   │   │   └── index.css
   │   │   │   └── view-notfound-error.php
   │   │   ├── ConsoleHelper.php # Pretty Printing for Console
   │   │   ├── Router
   │   │   │   └── Route.php # This File handles Routing, should not be modified, unless you know what you do.
   │   │   └── Viewer
   │   │       └── View.php # This File handles calling views, should not be modified, unless you know what you do.
   │   └── Model # Your Models directory
   │       └── UserModel.php
   ├── bundle # Files Which run by you in manual manner to handle certain things like env, helper function routes
   │   ├── Bundler.php # This File Bundles your App
   │   ├── Environment # Directory Which Setups your Environment Settings
   │   │   ├── DotEnvironment.php
   │   │   └── Environment.php
   │   ├── HelperFunction.php # Global Helper Functions are defined here
   │   └── Routes.php # Your Routes are defined here
   ├── composer.json
   ├── composer.lock
   ├── public # This Directory will be exposed to User Side, Static Assets should be placed in it
   │   ├── build
   │   ├── index.php # Entry Level File, Starting Point of App
   │   └── styles
   │       └── index.css
   ├── resources
   │   ├── scripts
   │   ├── styles
   │   ├── template
   │   │   ├── Controller.php # Default Controller Template
   │   │   ├── Model.php # Default Model Template
   │   │   └── View.php # Default View Template
   │   └── views # Your Views directory
   │       ├── main.php
   │       └── welcome.php
   ├── vendor # Application Dependecies and autoloader directory
   │   └── autoload.php # Include this to autoload files
   └── worker # Your Command Line Manager

Installation

  1. Make sure your composer version is atleast 2.9 or greater.
composer --version
  1. Run the Composer Command to Create Project
composer create-project dhruv125/ownwork 

# Or
# composer create-project dhruv125/ownwork ProjectName
# This is will create project in ProjectName Directory
  1. cd to Project Directory ownwork and Run composer run setup command.
cd ownwork/
composer run setup
  1. Edit .env file.
APP_NAME=Ownwork

DB_NAME=mysql
DB_HOST='127.0.0.1'
DB_USER=root
DB_PASS=

That's it, your OwnWork application is ready to run it's Hello World Program.

Usage

  1. Run The Server through worker script
php worker serve
  • Supposed Output:
Starting OwnWork server at port:8000...
[Mon Jan 01 00:00:00 2026] PHP 8.2.XX Development Server (http://localhost:8000) started

Or

Just Run Command

composer run dev

Documentation

  • Go through Documentation of OwnWork Here!

Recommended Packages

  • Since our OwnWork is really minimal Framework, you may require other packages for functionality like Database interactions.
  • Recommendations are:
    • delight-im/db: For database interaction - Github Link
    • phpunit/phpunit: For testing - Github Link
    • illuminate/support: For Illuminate Support like in Laravel

License

Ownwork Project is licensed under MIT License