I'm your Type-A 80ies computer kid turned web-dev in 2000. The line between stable long-term occupation and freelancer has been blurry ever since. This comes with the profession and the times we live in.
I've been in active in the industry for 15 years and now call myself a "Consultant & Software Architect" for FOSS and non-trivial web-applications (flashy name required for being taken seriously as a senior). The software we use at my current employer is matured FOSS, most of the coding is done already. 15-20% of the work consists of slapping together various pieces and building a whole project, adjusting preconfectioned webdesigns with some CSS and jQuery hacks on the side, maintaining the deployment pipeline, doing a little helpdesk, patching IT, etc. The other 80% are office, partner and customer politics, writing important sounding requirements-analysis and covering the companies ass on the technical side when we prepare to take on a deal.
If I would insist on only doing coding, I'd be one of the freelancers we hire to do the work for a few weeks, two or three times a year. One guy is a freelance web-guy, the other is a student who's good at Bootstrap and WordPress and is more into politics and probably has other long term plans than staying in webdev.
Since I'm important for deals and revenue I've got a part-time fixed position. Which is just the right fit for me and the company.
If everything goes right, our jobs, like most others will mostly be done by robots/software when we retire. Software is eating the World.
It's called progress and you should prepare for it.