Good question—this is one of those things that changes from city to city, and even from one bin type to another. There isn't a single rule.
For public street bins, the answer is usually: it depends on the design. A lot of urban trash bins are made with a removable inner bin or a heavy-duty liner bag. Sanitation crews pull out the inner container or bag, empty it into the truck, and put it back. That keeps the outer shell cleaner and makes collection faster. In busy areas, you'll also see bins with plastic liners that get replaced when they're soiled.
But plenty of city bins are designed to be dumped directly. These are usually sturdy metal or plastic containers with no removable liner. The truck's lifting mechanism or a worker empties the whole bin straight into the compactor. In that case, there's no liner to remove—just the bin itself, and sometimes a separate inner bucket if the model has one.
So if you're wondering whether you should use a liner: don't assume. For a public street bin, you generally just drop your trash in; you don't add or remove the liner. For a residential city bin, check your local waste guidelines, because some places allow bags or liners and others ask you to put loose material directly in the bin.
Short version: some urban bins have removable liners or inner bins, but many are emptied directly. The design and local collection system decide it.