I'm assuming by passive income you mean revenue that's generated from investing work and kicking back to profit. In that case -- it's all about creating products.
You could try selling books about Javascript, templates/plugins, or creating profitable apps and services. Get into affiliate marketing and advertise software with your coupon code (or just use Amazon and pimp your hardware setup). Write Medium blog posts behind their paywall. Install a questionable bitcoin mining plugin on a popular website you create. Write patented software that you can license to companies.
There's a myriad of profit models you can pursue, it's simply what you're willing to invest time and work into.
Ask yourself, what do people need and how can I provide that solution? And preferably, how can I provide a solution that works for itself (i.e; doesn't require any input).
The one thing to keep in mind is that there's really no such thing as "passive income". Unless you're someone in Hollywood making residuals off a movie, or getting checks from an old court case -- it takes consistent work to create persistent revenue. Products don't sell themselves.