When Spotify launched in 2008, Ken Parks heard one question again and again from journalists and investors: Why wouldn't Apple just kill this thing while it's still in the cradle?

Parks, the chief content officer at Spotify from its founding until 2015, had a simple answer: Because Apple (AAPL) probably didn't think it needed to.

At the time, Apple's iTunes store had a dominant position in the music industry -- but for downloads, not streaming. Spotify was competing less against giants like Apple than streaming services like Pandora (P), MOG, Grooveshark and Rdio, all of which except Pandora have since shut down. And Apple didn't appear too worried about streaming or this latest upstart doing it.

"Companies that have a very successful business model typically hew to that model unless forced to pivot," Parks, now the executive chairman at Pluto TV, told CNN in an interview last week.

It would be years before Apple, Google (GOOGL) and Amazon (AMZN) launched streaming products of their own. Each were framed in the press as "Spotify killers." None lived up to that title.

Ten years after it launched, Spotify filed paperwork last week to go public on the New York Stock Exchange. The move marks a major milestone for the company and could further boost its profile as it continues to take on the biggest names in tech, Apple chief among them.

Sign up for the PACIFIC newsletter and get daily updates on the stories you need to know

Apple was mentioned more than a dozen times in Spotify's IPO paperwork, starting with a victory lap of sorts on page one. The company notes that its user base is "nearly double the scale of our closest competitor, Apple Music."

Spotify survived thanks to its early mover advantage, a war chest of funding and the luxury of being able to focus on one core product rather than the vast range of pursuits at a company like Apple, company insiders and industry watchers told CNN after the IPO news.

"A couple thousand people totally dedicated to the task of maximizing the value of music and delivering the most compelling product to its users is going to beat a company for whom it's not part of the core business," Parks said.

And though Apple may not have paid it much attention early on, Spotify executives did pay close attention as Apple pushed into the streaming market. Pär-Jörgen Parson, an early Spotify investor and longtime board member, told CNN that leadership "saw a potentially difficult situation unfolding."

Parson said any initial concerns were eased somewhat by app data suggesting that users were more engaged on Spotify than Apple Music. "But obviously [Apple] could throw a lot of weight in terms of distribution power," he added.

In particular, Spotify took issue with Apple taking a 30% cut of subscription revenue from apps operating in Apple's App Store. The cut required Spotify to charge more to make the same amount of money, effectively cutting into its ability to compete with Apple Music directly on price.

Parson called it a "monopolistic situation." Spotify eventually complained to antitrust authorities. (Apple did not respond to a request for comment on this story.)

Related: The streaming music war is getting ugly

The actual Apple Music service was viewed as less of an existential threat, according to Parson and Parks. Spotify believed its focus on algorithms to personalize the music experience was a better bet than Apple's push for human curators.

Parks says Spotify also believed its free, ad-supported listening option offered "a key differentiator between Spotify and other services [that would] continue to drive mass scale in Spotify's paid user base." Apple only offers a paid subscription option.

"Spotify ... had a head start and built a great product," said David Pakman, a venture capitalist at Venrock and former CEO of eMusic. "They also have been able to raise a huge amount of money to cover the losses and unprofitable model."

The company had a net loss of $1.5 billion in 2017, more than double the amount from the prior year, stemming from the cost of licensing content. Those losses would once have been unfathomable for a startup, but Spotify was able to raise billions in debt and venture capital despite them.

Still, just because Spotify made it this far doesn't mean it's guaranteed to thrive as a public company.

Snapchat, for example, survived numerous clones from its much larger rival Facebook (FB) before going public. But in its first year as a public company it has struggled to show it can grow its user base in the face of a direct challenge from Facebook's Instagram.

Apple, like Amazon and Google, "can afford to run their services at a loss for many years longer than Spotify likely can, now that they are public," says Pakman. "The real question is how long will the public markets allow them to lose money."

In an unusual move, Spotify is not actually raising money in its IPO. Instead, it's listing existing shares on the public market. But Parson says Spotify could still turn to Wall Street to raise money at a later date for acquisitions and other investments to ensure it can keep competing with Apple as a public company.

Spotify won't be alone in that fight. Dropbox, another startup that Apple once vowed to destroy, filed for an IPO in February too. Both serve as reminders that David can still outmaneuver Goliath in the tech industry.