$$ \begin{aligned} 2 &= \frac{x}{6}&& \text{multiply ALL terms by } \color{blue}{ 6 }. \\[1 em]6\cdot2 &= 6 \cdot \frac{x}{6}&& \text{cancel out the denominators} \\[1 em]12 &= x&& \text{ swap the left and right side of the equation } \\[1 em]x &= 12&& \\[1 em]x &= 12&& \\[1 em] \end{aligned} $$