(CNN) The House of Representatives passed the final version of a massive farm bill Wednesday, clearing a major, must-pass item from the legislative agenda before the end of the year and the start of the next congressional session.

The bill, which passed both the House and Senate with strong bipartisan support, next heads to President Donald Trump's desk for his signature. In the Senate, the vote on Tuesday was 87-13, and in the House, it was 369-47.

The five-year farm bill is monumental legislation that addresses a wide range of areas including farming, nutrition, conservation, trade, energy and forestry.

Passage came after months of negotiations to merge the drastically different versions passed by the House and Senate earlier this year. While the last farm bill technically expired on October 1, many elements received funding through the end of the year.

The final version closely mirrors the Senate version and excludes contentious language in the House bill that was supported by Trump and would have added stricter work requirements for eligibility in the Supplemental Nutrition Assistance Program -- commonly referred to as food stamps. Several controversial forestry changes in the House bill were also left out of the final version.

Read More