Smart contracts managed through blockchain function just like any contract: one party meets a condition, which triggers an action by another party. Since a smart contract is simply a computer program or transaction protocol that automatically executes, controls, or documents legally relevant events and actions according to the terms of a contract or an agreement.
The objective of a smart contracts is to reduce the need for trusted intermediators, arbitration and enforcement costs, and fraud losses, as well as the reduction of malicious and accidental exceptions. In a word, it functions just like any contract: one party meets a condition, which triggers an action by another party.
While smart contracts are in fact covered by existing laws in effect since 2000 in the United States and elsewhere that allowed the use of electronic signatures to activate agreements and contracts, governments around the world are keeping themselves busy creating laws that specifically refer to blockchain, distributed ledger technology, and smart contracts.