As a freelancer you will have to identify and solve business problems. OSS and hobby projects may be good practice but no one pays for those, and most businesses don't care about side work.
Focus on identifying a business need or niche where you can add value. Java, Scala, React, etc. are tools, they are not solutions to business problems. Learn to listen to what potential clients say and ask questions, don't think just in terms of code and software. An example business problem is "My e-commerce site loses about 25% of customers at checkout" or "We'd like to use promotion codes for holiday sales." You will never hear a business say their problem is they need 2,000 lines of Python by next month.
I have some articles on my blog about freelancing, see my profile.