Well, the one I'm going to use is the best of course and quite simple

(Demo map coming soon™)
Create an array of base item types, a ring, amulet, artifact and so on. You can get away with just one of each.
Then create abilities, you can use item abilities as base. +hp, +damage and so on. Decide which stats are prefix bonuses and which are suffix bonuses. Set the abilities into arrays. The create string arrays so you can name your affixes. For example:
prefixes[1] = strength +1
prefixNames[1] = "Mighty"
suffixes[1] = damage +1
suffixNames[1] = "of Damage"
When a unit dies, randomize a number to see whther an item drops or not. If an item should drop, randomize the base item. Then randomize whether it gets a prefix and/or a suffix. If it gets one or both, save the index of the affixes for the item.
When a unit acquires/loses the item, load the affix integers, and set the level of the abilities accordingly. Get unit's level of x ability and increase/add/remove it.
You can give the items some dummy ability, so that when you left click the item, it shows the name and stats in a multiboard for example.
This way you can even create multile prefixes and suffixes just like in diablo 2 where you could have 3(?) of both resulting in very rare but sweet drops.
And you don't have to create tons of base items, only very few. But you can't show the stats in the tooltip.