It's simple:
Learn something new in a course, book, or on the job.
Put it in a flashcard.
Practice regularly.
And you will retain that knowledge.
Make your learning matter, and improve much faster as a developer.
This video from Osmosis, a learning product for doctors, explains the topic beautifully. CodeCode Ninja does just this, but for software developers.