Skip to content

Glossary: PHP Basics

type declaration

Also written: type declarations, return type

A note saying what type a parameter must be and what a function returns, such as `float $price` and `: string`. `: void` means it returns nothing.

Where the book teaches it

Related terms

declare(strict_types=1)TypeErrornullable