Of course it's illegal to run power cords inside walls. National Electrical Code 400.8 rolls through the things you can't do with cord, and it's mostly a list of schemes to use them as a substitute for the permanent wiring of a structure. Nope, just nope.
Data cables, on the other hand, can go right into the wall cavity. Punch a hole in the drywall and drop the cables down to another hole you've punched out; reach into the lower hole and fish the cables out, it's that easy. In fact, cable ducts that don't provide power are nothing more than a pretty frame for those holes. There's not even a real duct.
But take a close look at that cable duct that you linked. See the 2-socket receptacle built into the cable duct? Behind the receptacle is a proper junction box: it is to be installed using normal and proper wiring methods for in-wall wiring, such as MC, NM, UF or conduit. Separately from that, the data-cable hatch is just an opening into the wall cavity.
...or use an inlet
Some TV ducts come in two parts, providing an upper and lower duct. The upper duct has a receptacle but the lower duct has a power inlet, which is hardwired to the outlet via MC or other legal in-wall wiring method... as part of the kit. In that type, you plug an extension cord between the inlet and power strip you're using for the rest of the entertainment center. That lets you turn off the TV on a surge suppressor.
You ar also welcome to hire an electrician to install a receptacle and inlet, connected through the wall using proper wiring methods. Or DIY if you are able.
Cheat the rule - low voltage wiring
Some TVs actually use low voltage internally. Either they have a low voltage (e.g. 12V) input, or they use a "wall wart" or power brick to convert their power to low voltage before it even reaches the TV.
Low voltage circuits of 55 watts or less follow the same rules as data cables, i.e. You are allowed to run them inside wall cavities on flexible cordage. So if you are able to power the TV with low voltage, that is the way to beat the rule.