In this example we have an array named colors with color name and value. We show the checkbox for each color using ng-repeat directive and bind the checkbox with the color value either true or false. If the value is true then checkbox is checked and a box with background color shows and if value is false then checkbox is un-checked and color box will not show.