There was a lot of things which happened off-screen that the pocket books attempted to explain (albeit they were not canon).
Since it was stated on several occasions on screen that replicators convert energy into matter, replicating torpedoes (sans the antimatter) in parts and then assembling them wouldn't be too much of a problem.
The anti-matter on the other hand would be a bit pointless to replicate, since it would be easier to extract from storage or warp core, and it was stated in 'the cloud' that Omicron Particles could enrich the ship's antimatter reserves (probably working along the lines of cell division).
For reference sake, it was mentioned in early Season 1 that Torres could convert one of the impulse (or fusion) reactors into a crude dilithium (or was it deuterium) processing plant - bear in mind I'm operating from memory here, but it was stated.
We also saw Voyager looking for raw materials in various star systems such as Poliferanide (to repair damage to their Warp nacelles).
It is far from impossible that Voyager couldn't make pit-stops in uninhabited star systems and used solar radiation from a star for example to power their replicators and produce needed raw materials, in addition to making a crude anti-matter processing facility (also powered or supplemented by solar energy in addition to the energy being generated by the Warp core) which would allow them to replenish their supplies of torpedoes and antimatter in general.
Granted, this kind of thinking wasn't really shown because the writers obviously wanted to create 'drama' for the sake of it, but in the process, it ignores SF's technological capabilities (as they were seen using solar power as far back as the 23rd century with that Whale probe - and I would imagine that 80 years later, it would be a relatively simple matter to use solar power as an energy source for replicators - they do have energy converion technologies, and the Enterprise-D was seen harvesting various particles from Stars using a modified tractor beam - it stands to reason that either the hull or the tractor beam can be used for accumulation of massive solar energy - considering that it's about 22x higher in space than it is on a planet surface - which roughly equates to about 11 Zettajoules every hour - this is extrapolating from real life reference that Human civilization right now uses 0.5 Zettajoules every year, while there's enough solar energy hitting the Earth every hour to power Humanity for a full year).
So, it is possible that in the early seasons, there was more reliance on trade and salvage being done off-screen, and in the later seasons, the crew managed to perfect self-sufficiency technologies allowing them not to depend on external trade if they can avoid it.
Though trading some minor stuff for raw materials and anti-matter might have been faster/easier than making a pit stop and spending a bit more time with doing it themselves -and there's an additional question of how many suitable stars would be in their path, considering that they managed to go into a void which extended for 2500 light years (which doesn't make their deuterium woes in 'Demon' episode any less problematic - but I find it a bit strange they'd use deuterium in such a manner when the bussard collectors were described since the Original Series to effectively generate power all the time for the ship from background radiation and exotic particles).