Skip to content

Scaffolding in Programming

A scaffold is a temporary structure or work platform used for holding people, materials etc while making a building. This entire framework is called scaffolding.

In programming also we have a concept of scaffolding but that means we have an initial code which is a sort of automatically generated code, settings and folder structure used to start the project. This is like a skeleton app being generated and then you are required to write your code and logic. This helps to speed up your work.

Sometimes you would fire a command using a console and you will see ready made code generated for CRUD operations and thats what is scaffolding. Its a support code (scaffold) and then programmer takes over and writes better code.

You might get confused with the term boilerplate. Boilerplate is actually already generated code which are being reused in your project. But sometimes people may use it as a starting point (in case the boilerplate is well structured). You will find while scaffolding you are generating it via some tool using some command.

Scaffolding in programming was made popular by Ruby on rails as you might be aware of the commands such as scaffold :model_name which would generate controller and other code autoamtically. Later on other frameworks esp laravel, express, django and other php frameworks such as symfony, cakephp, akelos, codeigniter used it. There may be many 3rd party scaffolding tools available to support a framework. 


Leave a Reply

Your email address will not be published. Required fields are marked *