samedi 5 septembre 2020

Best praticies to organize folders for custom list in php

I am creating a custom lists in php and I want to know the best structure to implement it, suppose I implement an abstract class "custom list" and the lists extends it, what is the best way to folder structure to put extended classes take this example:

FirstRest class which use FoodList code:

<?php
class FirstRest{
    private FoodList $foods;
}

Structure 1:

|- Lists
|   |----- CustomList
|   |----- FoodList
|- Restaurants
|   |--------------- FirstRest

Structure 2:

|- Lists
|   |----- CustomList
|- Restaurants
|   |--------------- FirstRest
|   |--------------- FoodList

Aucun commentaire:

Enregistrer un commentaire