JavaScript how to make dough

Create a delicious testo with Javascript! Learn how to use loops, functions, and more to craft a tasty recipe with a step-by-step example.

Making Dough with JavaScript

Making dough with JavaScript is relatively easy, and can be done with a few simple ingredients. To make 1 pound of dough with JavaScript, you will need:

  • 1 ½ cups warm water
  • 2 ¼ teaspoons active dry yeast
  • 3 ¾ cups bread flour
  • 2 teaspoons salt
  • 1 tablespoon olive oil

To start, place the warm water in a mixing bowl and sprinkle the yeast over the top. Do not stir, and let the yeast dissolve for 5 minutes. The yeast will begin to foam as it dissolves.

In a separate bowl, whisk together the bread flour and salt. Then, add the flour and salt mixture to the yeast mixture, stirring constantly with a wooden spoon. Once the dough starts to form, add the olive oil and mix it in with the wooden spoon.

Next, turn the dough out onto a lightly floured surface and knead the dough for 8-10 minutes until it is smooth and elastic. You may need to add a bit more flour to the surface if the dough is too sticky. Once the dough is kneaded, form it into a ball and place it in a lightly oiled bowl.

Cover the bowl with a damp cloth and place it in a warm area for about an hour, or until the dough has doubled in size. Once the dough has doubled in size, remove it from the bowl and punch it down. Knead the dough again for a few minutes and then form it into a ball.

At this point, the dough is ready to be used. You can use it to make pizza, bread, buns, or whatever else you can think of. Here is a sample JavaScript code that can be used to make dough:


function makeDough(water, yeast, flour, salt, oil) {
  // mix yeast and warm water in a bowl
  let mixture = mix(water, yeast);
  
  // add flour and salt to mixture
  let dough = mix(mixture, flour, salt);
  
  // add oil to the dough
  dough = mix(dough, oil);

  // knead the dough for 8-10 minutes
  knead(dough);

  // form the dough into a ball
  let doughBall = form(dough);

  return doughBall;
}

// call the makeDough() function
let dough = makeDough(1.5 cups, 2.25 teaspoons, 3.75 cups, 2 teaspoons, 1 tablespoon);

And that's it! You have now made dough with JavaScript.

Answers (0)