; and (B) in subparagraph (A), in the matter preceding clause (i)— (i) by striking 2019 and inserting 2022 ; and (ii) by striking The preceding sentence shall not be construed as preventing a State during such period and inserting During the period that begins on October 1, 2019, and ends on September 30, 2022, the preceding sentence shall only apply with respect to children in families whose income does not exceed 300 percent of the poverty line (as defined in section 2110(c)(5)) applicable to a family of the size involved. The preceding sentences shall not be construed as preventing a State during any such periods . (2) Conforming amendments Section 1902(gg)(2) of the Social Security Act ( 42 U.S.C. 1396a(gg)(2) ) is amended— (A) in the paragraph heading, by striking until October 1, 2019 and inserting through September 30, 2022 ; and (B) by striking September 30, 2019, and inserting September 30, 2022 (but during the period that begins on October 1, 2019, and ends on September 30, 2022, only with respect to children in families whose income does not exceed 300 percent of the poverty line (as defined in section 2110(c)(5)) applicable to a family of the size involved) . 3. Extension of certain programs and demonstration projects (a) Childhood obesity demonstration project Section 1139A(e)(8) of the Social Security Act (42 U.S.C. 1320b–9a(e)(8)) is amended— (1) by striking and $10,000,000 and inserting , $10,000,000 ; and (2) by inserting after 2017 the following: , and $25,000,000 for the period of fiscal years 2018 through 2022 . (b) Pediatric quality measures program Section 1139A(i) of the Social Security Act (42 U.S.C. 1320b–9a(i)) is amended— (1) by striking Out of any and inserting the following: (1) In general Out of any ; (2) by striking there is appropriated for each and inserting “there is appropriated— (A) for each ; (3) by striking , and there is appropriated for the period and inserting “; (B) for the period