L2 visa is a dependent visa to accompany their spouse on L-1 visa. The duration of their stay is valid till their spouse’s L-1 visa is valid. If the spouse is a L-1A visa holder, then it is valid for maximum 7 years and if L-1B visa holder then it is valid for maximum five years.
On L2 visa, the spouse can study in US (part-time or full-time). But the major advantage for L2 visa over H4 visa is that on L2, dependents can work while on H4 dependents cannot. L2 dependents have to apply for EAD (Employment Authorization Card) with USCIS to be authorized to work in United States.
At a time EAD card is valid up to 2 years for L2 visa holder and then again it has to be renewed till the time they possess valid L2 visa status.
If your spouse plans to move to USA, then consider moving to USA on L-1 visa. One limitation for L-1 visa is that it is only available for multinational companies and L-1 is for inter-company transferees. That means while in USA, you cannot switch to some other company.
The key feature of L-1 visa is that there is no cap requirement unlike H-1B visa. Similar to H1B, L1 allows the holder to apply for a Green Card.