My parents mostly encouraged me mostly by providing the tools and leaving me to it; I spent some of my early years (pre-teen) reverse engineering/cracking (education only, never released), then an inordinate amount of time playing the Discworld MUD.
Once I got bored of BASIC my dad bought me some books on C++ and took me to a college course on PC building with him; though initially the college were reluctant to let a child take the course (I was 12). He'd often take me to work and answer all of my questions about what he was doing; PLC/panel-building at the time, with some very cool fibre optic tech and DIN rail mounted devices of all kinds; I'd help make wiring looms and labelling.
He and I would build a new ("family") PC every year until I got my first job after uni and could pay for my own damn computer;
He just uses laptops now and hasn't built or used a desktop since the last one we built together with my first pay-packet over a decade ago.