Refactor addon config generation to Project.prototype.config.