php - Just for learning, should I write my own framework without any components or tools, or just read the source code of an open source framework? -


i want understand how frameworks work. should make own framework scratch without using open source components or tools composer or phpunit .. etc. or read source code of open source framework symfony or laravel .. etc.

and should try not use composer , phpunit (for autoloading , testing)? me in learning process?

a question - why want , how php know?

a framework tool - idea is abstracts away (boring , mundane stuff) can more productive - in other words, idea don't need know how works or why works - makes life easier.

the frameworks relatively lightweight in not make page slower while, @ same time, increasing development throughput.

now obviously, need know framework in order use it, don't need know how works in detail, , guess question sits - why bother learning unless planning on making own framework or going customize - plan?

regardless, if underlying goal learn more php, not need frameworks.

now, stack overflow - instead of me asking questions in answer - going answer question:

the first part of question "i want understand how frameworks work" think have addressed above - why bother? learn php through projects, not through frameworks.

the next part, "should make own framework scratch" - here general programming question you, if asked go fetch data web service, yo go , write socket layer first, write negotiation protocols encryption, write string handling functions etc. - not - use library (curl?) instead, why? because know works, , better make - , save time. now, same true of php framework - if believe can better peer reviewed open source frameworks out there - go right ahead , give shot, unlikely topping charts against cake, laravel etc. time soon.

(a note here - there instance might want make own framework if have super specific problem none of existing general purpose frameworks solve, unlikely)

i going rephrase last part of question make blindingly obvious - instead of and should try not use composer , phpunit (for autoloading , testing)? me in learning process? think asking, in generic sense - "i want php project, should use quality of life tools composer , phpunit make life easier" - answer of course yes, if real project, there no point in creating proper project structure if doing week , going drop it.

i suggest think using gulp browser sync - read this, make life easier php projects, not 1 (as have kind of frontend output)

anyway, hope gives food thought :)


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -