I cycled to work for more than 15 years & still do. My commute is about 5 miles each way and westside traffic here in LA can take an hour some evenings when driving a car. Doing it by bike takes about 30 minutes.
I've had four e-bikes that I've owned over the past decade, in part to let me get to work without sweating and needing a shower upon arrival. The fact is they are fun, efficient and practical here where we have biking weather more than 300 days a year here. The roads are pretty good and I generally take less traveled side streets parallel to the major arterials. A few years ago a light rail line was completed going from Downtown LA to a couple blocks from the Santa Monica pier. As a part of that project, a segregated bike path runs along the line and accounts for about half of my commute to and from the office now. (It's wonderful!!!!!)
Bikes are bikes and there are thousands of variations...what works for me may not be what you are looking for. There are a number of types and manufacturers as shown in previous posts. I generally like what amounts to a beach cruiser style of bike as a commuter. They are heavy but sturdy, can accommodate panniers (bike saddlebags) and work quite well transporting my 5'10" 280-something pound body around. All of mine have been Class 2 bikes, meaning they are legal to ride on city streets, bike lanes, bike paths and trails, but are restricted to not go more than 20 mph. I add lights which I use day and night to be more visible, fenders to keep the tires from kicking water up on me & wear a helmet when I ride. I also took a safe city streets riding course from the local bike coalition to get a better sense of how to approach traffic.
Two of the bikes I own(ed) were made by a company called iZip and were the "Zuma" model. E-bike designs have trends. The first one we got had the battery in a cage above the rear wheel, creating a book rack above it. It had a throttle and was quite zippy. I got it partially by accident when I put in a winning bid for a fundraiser not thinking that no one would bid above me. I already had three other bikes and I ended up surprising my wife with it for a birthday! She rode it to work about 2 miles for a year and then moved to a job 45 miles away and had to go back to driving. I used it for commuting for several years after that. One thing to note is batteries degrade, much like electric car batteries do. I replaced them with a rebuild from a battery shop outside Las Vegas. The rebuild cost around $600 then. The bike is in occasional use now in Austin where one of my sons took it with him when he moved there a couple years back.
The other Zuma followed a newer trend of having the battery under the seat as part of the seat post, in a compartment built into the frame. The theory was a lower center of gravity was preferred. I added a bike book rack and panniers which clip on to the rack. I still have that bike after riding it for more than six years. Unfortunately this bike had a design flaw where the gear that engages when you pedal forward and releases when you pedal backwards was a cheap plastic internal piece that slips when any significant torque is engaged on the pedals. I had it replaced twice under warranty but the part was just a defective design and it wasn't easily substituted. I still have this bike and use it mostly in full on electric mode, riding up and down a segregated bike path to the beach mornings to go body surfing or surf boarding. It's about 7 miles each way and works well for this, still with the original battery. Both Zuma's have a rear hub motor to propel them.
The third e-bike is a related brand of the parent of iZip, Accell Group, a Raleigh Sprite iE, which essentially is the same bike as the Zuma and may come from the same factory. The trend update on this design was to move the battery to the front down tube, mounted external (bolt on) to the frame in a more slender case that is removable. There is a key'd lock to secure the battery. The motor is now integrated to the pedals and assist driving the chain that powers more like a traditional bike. It didn't come with a throttle but was pre-wired with a connection for an optional thumb lever throttle which I got.
It doesn't have quite as much use on it as the others due to Covid work restrictions and working from home most of last year. This bike I picked up on a black Friday sale from a local bike shop three years ago and use it now as my primary commuter.
Battery range on all these bikes depend on how you ride them. New they all comfortably went 25 miles. The sales information claimed 35 but I never got that from them. I tend to ride mine between 11 - 14 mpg which gives me reasonable speed while not taxing the battery too heavily to get me the distance I desire. The three year old commuter tends to go round trip with range to spare on a single charge. The iZip beach bike maxes out now around 16 miles which is fine. I'm able to go to the beach before work, come home and shower, eat and ride the commuter to and from work. That may sound weird to you, but it works for me as it saves on gas and parking fees. As I mentioned at the beginning these are far more FUN to commute on than driving a car. There is just something about the open air and taking the side streets that lets you experience the neighborhoods that being boxed up in the car doesn't reveal. When I began commuting by bike I was was riding a traditional road bike and wore spandex bike clothes. With the e-bikes I wear regular clothing and again don't need to change when I arrive at a destination.
Each bike ran between $1400 - $2000 complete (price, sales tax & accessories (Lock, lights, panniers, fenders, helmet). All I purchased on sale. I should add there is a maintenance factor to all these bikes when using them to commute regularly. Tune-ups, brakes, tubes and tires get replaced and with heavy use you should budget a few hundred dollars a year for this.
There is a fourth bike which was a conversion kit to a cargo bike. It worked but I had issues with the kit and the bike is out of service these days tucked away behind the garage.