By default, multiple selection is enabled for the checkbox, and we can have a single selection by enabling the binary attribute. A basic example of a checkbox with a single selection would be as follows:
<p-checkbox name="single" [(ngModel)]="checked" binary="true">
</p-checkbox>
In the preceding example, the boolean checkbox is used to know the interest of Angular framework. The component will be displayed as shown in the following screenshot:
The preselection of the checkbox is also possible by enabling the Boolean property in the model.