Well, both not quite right here. Any digital recording technique involves "sampling" of a real-time sound wave. Sampling techniques can seek to improve accuracy by way of bit depth (how much information recorded in each sample) or the rate at which samples are taken. So the samples can come quite close to re-creating the original wave, but at the end of the day, sampling is an approximation and the integrity of that initial sound wave is compromised.
In contrast, analog recording techniques and vinyl reproduction maintain and replicate that original sound wave, but the mechanical realities of a phono needle tracking record grooves impose limits on the lowest bass frequencies, the highest frequencies, and the dynamic range (loud to soft) that can be replicated, including the noise floor, below which musical signals cannot be heard. Meanwhile, optimized digital data provides a much wider dynamic range, including a much lower noise floor. It also may not be subject to the physical degradation associated with vinyl - scratches and pops. However, in practice, many digital signals are NOT optimal; compression techniques - MP3 in particular - trade sonic data for storage capability, so that the sampled material - already an approximation of the original soundwave - is further compromised.
If you have the ability to to compare a tune across MP3, typical CD "Redbook" standard, digital resolution via data streams exceeding the Redbook standard, and good vinyl playback, you'll likely flee from all of your MP3 sources (although for digital streaming of radio programs or for reasons of convenience, you may be stuck). You can hear the promise of digital in the way of dynamic range and lack of background noise, but for many listeners this is a trade-off for coloration or incomplete resolution of timbre and timing cues, as well as spatial information relating to performance in live spaces.
I'm not doctrinaire - I love the convenience and enormous breadth of availability through streaming (I use a premium Tidal subscription), I like the sound and convenience of CDs, and by the mid-1990's, CD recording techniques locked in to provide - for me - a more satisfying experience. But I'm spread across two locations and the CDs are mostly in one place, which also is where my 3000 phono records are stashed - I never gave up on vinyl, and have a lot of obscure jazz and world music material that does not show up in streaming libraries. On streaming, I detest a ridiculous royalty structure that denies creators from reaping appropriate value from their work, and only adopted streaming once I was in the two-location mode, and realized that ripping all of my CDs would be a gargantuan task for which I have no patience. Overall, I prefer vinyl for certain things, CD or high-sampling rate streaming for others, but happily live with all (except MP3 or other compressed formats), depending on convenience.
One caveat - over the years I've been able to develop high-quality audio playback systems in each location, and suspect that low-resolution playback might mask the sonic differences I've addressed. If you're relying on desktop speakers and meh amplification, maybe MP3 is fine...and that's cool. But if opining with broad pronouncements re the virtues or vices of digital vs. analog, consider the breadth of your experiential base.