Live data from Hacker News

“Don’t Reinvent the Wheel, Use a Framework” They All Say

mogosselin.com

11–20 of 94 posts

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#11
post #5

I can fully appreciate this. Abstraction takes the fun (or spark) out of programming, all we really do these days as developers is glue framework components together.

Unless you're programming in Binary or manipulating the hardware directly, every programming task is built on layers of abstraction. You just have to decide what level is best for you and the project you're working on.

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#12
I don't think the article does a terribly good job of arguing the point, but I agree with the thesis in so far as it applies to my very limited experience.

I made A Soft Murmur [1] without ever having written a line of code before. (There are literally comments in the code like "oh, so that's what an array is".) I originally planned to use jplayer [2] for the audio because I believed it had very good cross platform support. But after I dug down deeper (and wasted quite a bit of time), I discovered that for what I actually wanted to do (control multiple audio streams from the same set of controls), jplayer had poor cross-platform support: for example, on iOS every audio stream has to be started by a user action, so it's not possible to play multiple streams by tapping once. There were a number of problems like this. The issue was, because I was so much of a novice, I didn't know how to assess jplayer's limitations to the degree that a more experienced developer would have before choosing to use it.

Similarly, I used jQuery Mobile [3] to create mobile-friendly sliders for audio volume control, but then spent a long time working out to disable all the other things jQuery Mobile does by default.

I ended up using raw HTML5 audio elements, and I kind of wish that I'd implemented the sliders and the rest of the controls in vanilla js rather than jQuery and jQuery Mobile. I would have learned more. As it is, my understanding of what jQuery actually offers is hazy because I'm unsure about how much I could have done without it.

My takeaway is that until you know the basics of a language, you can't tell what tools you need or the limitations the tools you chose will impose on you. I think it's far better for beginners to start using the absolute minimum set of tools (in my case, hand-coded HTML, CSS and JS) and then add more complex tools when one encounters a problem one can't solve with what one already has, or to optimize something one already knows how to do.

[1] http://asoftmurmur.com

[2] http://jplayer.org/

[3] http://jquerymobile.com/

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#14
Who cares which language, library, framework, tool etc. are you using? Just get the job done! There is no "ultimate" solution. Software developers tend to attach too much importance to tech stack - in most cases it just doesn't matter, as long as it works.

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#15
post #7

Well, take what I say with a grain of salt since I cannot call myself a programmer, but you can’t mix it all. Take Flask, I mean, who the hell wants to do url routing? Flask does that for you. Take sqlalchemy, who the hell wants to create an orm? It’s nice to learn the basics, to understand python well and to understand web development foundamentals like “salted”/hashed passwords etc. But don’t tell me I should have…

[deleted]

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#16

I disagree with this article, almost entirely for the list of reasons given right at the end of it. Good development practices and project structure, generally good code examples, fewer bugs and tested code and re-using code are all very important things in any development, and frameworks all help with that. If you are starting some of your very first web development, I'd encourage you to play around with some low le…

"The projects I know that were developed 'without a framework' are more often than not poorly structured, poorly documented, and difficult for new developers to learn their way around"

You are right! I didn't mean that I would like beginners to code 'Production Code' without any frameworks and do all their stuff themselves.

Especially if it's a big application, this would mostly result in 'unmaintainable spaghetti code'.

What I meant by beginners: "People learning to code", not "Beginners doing a production code without any help from more experienced programmers" ;)

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#17
If you write without a framework and you want to create robust programs, you're going to spend a lot of your time learning to deal with deficiencies of the web which you wouldn't have to worry about if you were learning native mobile or desktop development.

Do we really want to force people into learning how to wrangle strings from an field into valid dates or how to manually CSRF proof their forms to do basic web-dev?

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#18
We should be careful not to confuse "frameworks" with "libraries". Two very different things. The former, yeah I agree that newbies should steer clear of until they understand what's really going on, and have the knowledge to dig deep and take advantage of the power those frameworks give you, rather than using them as a folder setup and "automagic".

I'm currently working on a series of articles (maybe a small ebook, unsure yet) on developing applications in PHP -- sans frameworks like Zend, Laravel, Symfony. All those force a way of thinking that is very powerful if you're a good software engineer and web developer, but allow for a novice to build things while not learning the "right" way to do it.

So, PHP 5.5, Composer, and Packagist, combined with the PSR4 mean that a complete novice, and a hardened web dev, can take small composable libraries and create powerful reusable applications and libraries themselves, with best practices and great code. It's the anathema to PHPs historical shittyness. It's how I've been building my current startup. It's the future of PHP web dev, side by side with those big frameworks for when you need the big guns and a large team, etc.

It's made developing in PHP awesome, and I never thought I'd say that. Now the issue is in educating others to give it a try :)

Re: “Don’t Reinvent the Wheel, Use a Framework” They All Say

#20
I agree. I think you should start with basic HTML/CSS/JS. Otherwise you will never learn the basics and figure out what/how the frameworks actually work.

Take Bootstrap for example. A beginner starting with frameworks might think: "Cool, if I add class this and class that, I get styling and layout". When in reality you need to know that class name means nothing, it is the CSS in the back that is doing everything.

Start basic, otherwise you will never know how exactly the frameworks work. Plus, you will never be able to write your own frameworks/libraries/code since you didn't learn it!

PS: The answer "just use a framework" = add a whole new file to use 10 lines of code and bloat your website with extra files and slow load times.

Post reply on HN