Yes, but the purchase and loan are in nominal dollars. Taking GP's example numbers, a $500 house, bought with a $100 downpayment, in a house and general inflation environment of 3%pa, and an interest-only mortgage (to make the math napkin friendly)
You start with $100.
You buy a $500 house. $0 cash, $500 in asset, -$400 in liability.
A year passes. $0 cash, $515 in asset, -$400 in liability.
A year passes. $0 cash, $530.45 in asset, -$400 in liability.
After 30 years, $0 cash, $1213.63 in asset, -$400 in liability.
That $100 turned in ~$814 of equity in 30 years. That equity has the purchasing power as today's $335. Even though inflation and asset prices rose by 3%, your $100 grew in purchasing power at a CAGR of 4.11%.
Contrast that with an unleveraged investment that also rose exactly with 3% inflation.
You start with $100.
You buy a $100 bond. $0 cash, $100 in bond.
A year passes. $0 cash, $103 in bond.
A year passes. $0 cash, $106.09 in bond.
After 30 years, $0 cash, $242.73 in bond.
Unsurprisingly, that $243 30 years from now has the same purchasing power as $100 today.