In the one-variable case, linearization is based on the Taylor approximation.
We begin by considering scalar-valued functions of multiple variables.
In practice, differentiating $g: \mathbb{R}^n \to \mathbb{R}$ with respect to $x_i$ amounts to treating every other variable as a constant and differentiating $g$ as if it were a function of the single variable $x_i$.