Explanation: In the 1820s, many American Southerners, seeking new lands that hadn't been ruined by wasteful and primitive farming techniques (as were practiced by American Southerners of the time), emigrated into the Mexican holding of Texas. The thing is, they often brought their slaves with them - and Mexico would outlaw slavery in 1829 (and then American immigration in 1830).
It didn't stop the influx of American emigrants, slaver and non-slaver alike, who saw Texas as prime unexploited farmland. In their defense, Mexico saw it that way too, and was less concerned about American settlers increasing the tax base, and more concerned about... well, what would eventually happen - American settlers eventually clashing with the dictates of the government.
The spark that lit the eventual revolt of Texas was actually nationwide - Mexico had devolved into civil war over the issue of centralized power vs. federalism. Texans ('Texians', at the time) sided with the Federalists, and initially things seemed like they might resolve favorably for Mexico, with the Anglo-American Texian settlers mollified by the Federalist reforms proposed. However, when the Mexican general Santa Anna couped the Federalist government and instituted a Centralist dictatorship in its place, new Federalist revolts rose up across Mexico. Santa Anna's government managed to repress all of them, except Texas - in no small part because of Anglo-Americans having economic connections across the border to the USA they could leverage, and because Anglo-Americans outnumbered Mexican settlers in Texas by that time.
Texas would declare independence, and a decade later, be annexed by the USA by their own request. Mexico was not happy about this, and this dispute started the Mexican-American War - wherein the USA invaded and eventually annexed much more of Mexico than just Texas, and which many in the US (and Mexico, almost certainly) would come to regard as an imperialist war, an unprincipled grab for land, regardless of whether they thought annexing Texas itself was legitimate.