[description] + 的 + [noun]
[description] + 地 + [verb]
[verb] / [adjective] + 得 + [comment]
的, 地 and 得 sound the same, and in writing the choice depends on what comes next. Before a noun, 的. Before a verb, 地. After a verb or adjective, followed by how it went, 得.
Whatever describes a noun – an adjective, an owner, a clause – takes 的 and comes in front of the noun.
地 turns a description into the manner of an action. It sits between the description and the verb, and the verb comes after it.
得 follows the verb or adjective and introduces a comment on it – a complement, a phrase after the verb that says how well, how much or with what result. The verb comes before it.
One description can take all three, depending on what it attaches to.
The commonest slip is 的 after a verb where 得 belongs. Check the side the verb is on: verb first means 得, verb after means 地.
You'll see 的 used for 地 in casual writing online. In your own writing, keep them apart.