Personally, as a young adult, I would not want to tie my finances long-term with my parents, especially first starting out, but as long as everyone is clear on their role, it could work out. Who would determine when it’s time to sell? You or them? You say they will get the money back that they put in? Does this mean after the sale that they will just claim what they put in as the down payment, plus any cost and repairs they put into the house over the years and let you keep the rest? How put out would they be if you decided to move after a few years? What are the back up plans for in case that happens? Will they sell earlier than expected? Would they be comfortable finding in managing tenants from across state lines? Get a property manager? This is what I meant by I personally would not want to tie my finances to someone right out of the gate. That would mean having to consider others in major life decisions, such as moving and where to live.
As long as you get everything sorted and clear, it could definitely be a boost to you financially to be able to get your rent back, especially if you have a roommate(s).