6 ms·
Nice work! A micro-micro-framework, makes Slim and Silex look big.
by alphadevx 12y ago
Nice work! A micro-micro-framework, makes Slim and Silex look big.
- arenaninja 12y agoIt is nice, but having implemented something like this myself at work recently, this looks eerily familiar and some things about it bug me. For example, why is ReflectionClass not used (I'm guessing PHP 4 compatibility)? Particularly because class_exists can cause major headaches if you use the default autoloader, see https://bugs.php.net/bug.php?id=52339 https://bugs.php.net/bug.php?id=52339 There's also little information available from outside the router; an invalid class/method uses die without giving you an option to check for it and handle it some other way. I also don't immediately see any special handling for not allowing magical methods to be called Definitely a good start for personal projects though, just needs some spit and polish
- apsdehal 12y agoThanks for your concern, I would try to implement features you have said, Its still under development mode and needs much polish.
- arenaninja 12y agoGood luck! Another feature of my router is that the method name converts snake_case to camelCase, so that resource/list_actions calls ResourceController::listActions(), but some of the features I mention will most likely incur a performance hit, but it shouldn't be significant once opcache comes into play