There are pretty established accounting rules for this.
For valuing digital goods?
Are those rules smarter than looking at the money it took to make? If so please share where I can read more.
If not, then despite being "established" the problem isn't solved.