Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide .get(), .set() helpers, refactor config #126

Closed
wants to merge 1 commit into from
Closed

Provide .get(), .set() helpers, refactor config #126

wants to merge 1 commit into from

Conversation

robertrossmann
Copy link
Contributor

This provides the .get() and .set() functions on app.config object.

.get()

The function takes a string, which will be treated as an object path to a property on the config object. If that property exists, it will be returned, otherwise it will default to undefined.

.set()

The function takes a string, which will be treated as an object path to a property on the config object and a value, which will be set on the given property path. If any properties in the path do not exist, they will be created.

I refactored the whole config stuff into its own class to provide better encapsulation.

Closes #124

@robertrossmann
Copy link
Contributor Author

Please do not merge, alternative approach might be chosen. Discussion continues in #124. I'll leave this open for the time being.

@tjwebb
Copy link
Member

tjwebb commented Apr 25, 2016

@Alaneor closing until we settle on a solution. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants