Using Frameworks to Build Websites and Web Applications

web framework

Even if you only build websites using CMSs, you’ve probably heard the word “framework” before.

You’ve probably also heard of a few famous web frameworks, including Ruby on Rails, Django and Bootstrap.

Many experienced web developers build websites using frameworks and often find them easier and enjoyable to use.

In this tutorial, we’re going to explain what a framework is, and when you might use a framework.

If you are currently doing one of the OSTraining Coding classes, this information will prove especially useful to you.

If you are just using a CMS, this post will still contain some valuable insights, as many CMS systems can and are built using frameworks. For example, Drupal 8 is currently being built on Symfony and Joomla 3 is using the CSS framework Bootstrap.

What is a framework?

The goal of a framework is to allow designers and developers to focus on building the unique features for their project, rather than re-inventing the wheel by coding common, familiar features found across many websites and web applications.

A framework can be considered a pre-built template/structure that handles most of the repetitive or common features. As a result, unlike a CMS, a framework will probably not have a user interface (although this is not always the case, as Django provides an administration interface). Most of the activity will be done by writing code and interacting with different parts of the framework itself through code.

Often frameworks take a while to learn, but once you’re familiar with them, they should speed up your development time.

When should you use a framework?

You can measure the need for a framework based on 2 broad topics:

  1. The level of customization you require: A good way to explain this would be to use an example. Say that you are running a company called Company AA with around 40 employees. You recently read a study that indicated how social interaction both in the workplace and online can drive innovation in your company. You want to employ this idea but you feel that using a public tool like Facebook or Twitter cannot address the solution of having a private and custom social network among your employees. You have also evaluated ‘plugins’ available for your CMS, but none of them quite fit the desired layout and interaction you’d like from your social tool (without a lot of hacking to get it to work). You therefore consider getting a custom development done for this project. As you can see, the above example indicates that the greater the level of customization, the more likely you would be using a framework. However, this also depends on point 2:
  2. The developers you employ: If you aren’t going to do the development yourself, you will likely want to employ a team of developers (or a freelancer – depending on the size of the project) to do the work for you. Although a lot of developers do use open-source and freely available frameworks, some prefer to use their own custom-built internal frameworks and some choose to not use frameworks at all. Just like most communities that voice their opinions, the programmer community does so on many aspects, including the actual language used, the design pattern, the way the code is written and of course, multiple aspects concerning using frameworks. The choice developers make in whether or not to use a framework leads us to the next part of this blog, which is concerning the pros and cons of using a development tool like a framework.

5 advantages to using a framework

  1. Open-source: Most of the popular frameworks in many languages are open-source (or available to use for free). They also come with licensing that isn’t restrictive and allows you to build commercial products using such frameworks
  2. Documentation and support: Although this can vary (if the language being used is popular and the framework has a lot of developers using it), you can expect that the framework will either have good documentation, good support or both at the same time. It is worth mentioning that “good support” is a subjective issue at times. Typically, paid support will almost always be faster and more concise, but this also depends on the level of activity within the framework – as a framework like Ruby on Rails demonstrates with a massive community, which is renowned for its welcoming nature and good support too.
  3. Efficiency: This could be considered the most vital reason why frameworks exist. They eliminate the need to write a lot of repetitive code that you will find being used in many different applications. These include, for example, user-authentication and commenting systems. On average (if you have sufficient knowledge using a certain framework) you can expect to build a project in much less time than would be achieved writing code without a framework
  4. Security: Typically, a framework is developed and tested by many different developers. It is extremely likely that many security risks are addressed and tested when the framework is being built. New security risks can also be addressed and fixed quickly. However, security can also be considered a con, as will be mentioned in that section
  5. Integration: If you are building almost any type of application (including a website) and you want to store some data, you will typically use a database. Just like a database, there also exists many other tools that link to web development. Many frameworks will thus make it easier to link to these tools and also communicate with them (for example, when “talking to” a database is abstracted away in a certain framework, making communication with the database much easier)

5 disadvantages to using a framework

  1. Limitations: Generally, you will not be able to do almost anything with a single framework. They are all restricted in some way, from coding paradigms to database designs and everything in between. A good way to work around this is to see what the framework is being used for by other developers in the community, as this will give you an idea of what you can achieve
  2. Performance: With the popularity of client-side JavaScript MVC frameworks like AngularJS, EmberJS and BackboneJS growing since 2012, performance can also be considered a factor. Although performance issues did exist before, they weren’t as relevant as today, where an entire application is loaded through JavaScript, using a framework as the tool for building that application. Whereas you might not feel the impact of loading a 75kb compressed-framework .js file on your PC (with high speeds), this .js file will definitely impact mobile users (who may have slower speeds on their smartphones or tablets)
  3. Learning bias: If you decide to learn how to use any framework from some programming language you are familiar with, chances are that what you learn will be somewhat different to the language itself. This is due to the fact that a lot of those repetitive tasks have been created in custom functions and other parts, which is why you will learn such things that may not have existed in the language lessons itself. Apart from that, you may also learn a lot of things that may be irrelevant to you whilst using the framework in real-life, but are necessary to grasp how the framework works
  4. Steep learning curve: Although this isn’t always the case, most frameworks can be difficult to learn and and even more difficult to master. After some simple research into this matter, a university professor said that it will take about 2 years (with no programming background) to become familiar and comfortable using a language (Ruby) combined with a framework (Rails) (see here for details). This may not be the case when being self-taught or having years of programming experience, but I would say that even with experience, at least 3-6 months will be needed to become confident using any framework (based on continuous learning and practice)
  5. Cost: Frameworks require more development experise and experience than most CMSs. As a result, it can be more costly to hire reliable framework developers than reliable CMS developers. In my experience, the average project built with a framework is more expensive than a similar project built with a CMS.

Examples of popular frameworks

Below are some popular web frameworks (in no particular order) for different web languages. This is not an extensive list, as there exists many more options out there.

PHP:

Ruby:

Python:

JavaScript:

Design/CSS frameworks:

Over to you?

Have you built any websites using a framework instead of a CMS?

What were the advantages and disadvantages of going with a framework?

Share your feedback or any other experiences below.

Author

  • Steve Burge

    Steve is the founder of OSTraining. Originally from the UK, he now lives in Sarasota in the USA. Steve's work straddles the line between teaching and web development.

    View all posts
0 0 votes
Article Rating
Subscribe
Notify of
guest

19 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Bob Jones
Bob Jones
10 years ago

A list of Java frameworks would be great, too! Start with Grails 🙂

steve
steve
10 years ago
Reply to  Bob Jones

Thanks Bob. Yes, that would be a good addition.
Looks like there’s a sizable list here: [url=http://zeroturnaround.com/rebellabs/the-curious-coders-java-web-frameworks-comparison-spring-mvc-grails-vaadin-gwt-wicket-play-struts-and-jsf/]http://zeroturnaround.com/r…[/url]

patrick
patrick
10 years ago
Reply to  Bob Jones

Play! looks promising too. I’ve been playing with it a little.

steve
steve
10 years ago
Reply to  patrick

Thanks Patrick. I’m starting to think this little PHP & Javascript outfit of ours should start dipping our toes into Java too 🙂

snehal harshe
snehal harshe
3 years ago
Reply to  steve

Impressive. Keep up the good work

John
John
10 years ago

Thank you for the time and effort to make a comprehensive post.
I would comment on one statement.
Quote”… Due to the code being open source, it can be analyzed for any exploits more easily…”
All the main CMS are open source as well. I think the factor of the .js, framework code, or whatever code you import into a project that is open source, is equally subject to malevolent eyes.
The teams that support an open source CMS, being teams, have a responsibility to respond to security threats just as much as the team that supports a framework. I think what you possibly meant to convey, was that if you are going to “roll your own” project using a framework, the onus is on you and your project team, to perform due diligence for best coding practices for the code you write. Then best testing practices to protect against attacks should be implemented. At the end of the day, you then are taking on a greater responsibility for using all the best practices everywhere. (You should anyway!)
If then, using a framework you find a security flaw, I feel there is a responsibility to submit a suggested patch to the team who’s framework you are using, beside just patching the FW code yourself for your own use.
“With added flexibility comes added responsibility.” is always true.
Again, thank you for a helpful post.
-John

steve
steve
10 years ago
Reply to  John

Good catch, sorry for that John.
That part originally got taken out during the editing process and accidentally slipped back in.
We’re firmly of the belief that open source software is more reliable than closed source alternatives.
However, it looks like we need to make our editing workflow more reliable …

web application Rochester NY
web application Rochester NY
10 years ago

I was looking for something like this.. really a good and interesting post to read for..

Amin
Amin
9 years ago

Wondering why AppGyver Steroids has been left out of this article? Seems to me it would be of interest to people looking at the top frameworks. It hits on all of your discussion points. On top of that, Steroids employs Angular and the ionic framework CSS library.
[url=http://www.gujaratrecruitment.com/]http://www.gujaratrecruitme…[/url]

mathew delport
mathew delport
9 years ago

Thanks for your detailed information; your post on PHP is

very useful for me. [url=http://www.fita.in/php-training-in-chennai/]http://www.fita.in/php-trai…[/url]

Mohamed Shiyas
Mohamed Shiyas
9 years ago

PHP is most popular programming language used to create responsive

and dynamic websites. This language is loaded with various advanced suites that

make development process lot easier. [url=http://www.fita.in/php-training-in-chennai/]PHP Training in Chennai[/url]

Linda Canas
Linda Canas
7 years ago

Thankyou! Very well written article.
Hvantage Technologies is one of the USA leading website design, web promotion, software development and web Development Company. We provide time bound, cost effective and value added services for technology innovative business solutions that require specialized domain expertise. We also provide responsive website designing. You can call us or mail us for getting the more information about the services and visit us: [url=http://www.hvantagetechnologies.com]www.hvantagetechnologies.com[/url]

Jessica Barnes
Jessica Barnes
7 years ago

The bottom line is, a framework is a software or code written to help you be productive. It is a skeleton, a comprehensive set of tools that were built for the purpose of enabling you to focus on one or more specific tasks. You take that skeleton and build your application on top of it.

Data Science Course
Data Science Course
4 years ago

Very nice blog and articles. I am realy very happy to visit your blog. Now I am found which I actually want. I check your blog everyday and try to learn something from your blog. Thank you and waiting for your new post.

Mikall Hill
4 years ago

Thank you so much! We are very happy that you found our blog and visit often.  We appreciate your support and hope you find a lot of useful information.

Tarun Nagar
Tarun Nagar
4 years ago

The blog is absolutely fantastic! Lot of great information which can be helpful about benefits of developing website. Keep updating the blogs.

digital marketing services
digital marketing services
3 years ago

I use to read blogs on daily basis for new informations, your this blog is one of the best information i come to read today. Hope you are doing same work for new updates.

Digital Marketing Services in delhi

Snehal Harshe
Snehal Harshe
3 years ago

Thank you so much for sharing all this wonderful information !!!! It is so appreciated!! You have good humor in your blogs. So much helpful and easy to read!

Saiprashnavali
Saiprashnavali
2 years ago

informative stuff, thanks for sharing the list of frameworks.

19
0
Would love your thoughts, please comment.x
()
x