4. Framework

Now that we have our git repository, we’re going to install the tools we need to start building a page.

4.1. What is a framework?

The first and more important is our framework.

What’s that? Nothing more than fancy name for a set of software tools that, working together, can stand up a website.

It takes dozens of different software tricks to pull a good site together. Frameworks aim to make the challenge easier by curating a set of time-saving tools.

There are a lot of different frameworks out there. Maybe you’ve heard of some them, like Django for Python, Rails for Ruby or React for Node.js.

Each newsroom tends to go its own way, picking and choosing among the most popular tools. While the programming languages and the details vary from shop to shop, the fundamentals are almost all the same.

The GitHub template we cloned in the last chapter is a demonstration of the Los Angeles Times tool, which is known as baker. It is published as free and open software that anyone can easily reuse at github.com/datadesk/baker-example-page-template. It’s also been used by developers at ProPublica, The City and The Baltimore Banner.


Other newsroom frameworks have been released as open-source software, such as:

4.2. Install our system

The Times’ baker framework — like most of its peers — is developed using the Node.js programming language.

Installing the underlying dependencies necessary to develop a page requires that you use Node.js’s package manager npm.

From your terminal, positioned inside of the repository’s directory, run the following to install everything necessary to start work:

npm install

4.3. Start the test server

Once the dependencies have been installed, you’re ready to preview the project. Run the following to start the test server:

npm start

Visit localhost:3000 in your browser. There you can see the generic website offered as a starting point by our framework.

npm start and the first page you'll see

Congratulations, you’ve got your framework up and running. Now we’re ready to start developing our story.