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

could you please add an example of minimal configuration? #22

Closed
cordoval opened this issue Apr 5, 2014 · 7 comments
Closed

could you please add an example of minimal configuration? #22

cordoval opened this issue Apr 5, 2014 · 7 comments

Comments

@cordoval
Copy link
Contributor

cordoval commented Apr 5, 2014

No description provided.

@matthiasnoback
Copy link
Collaborator

The load() method accepts an array of config values. When no argument was provided, the getMinimalConfiguration() method will be called and it should return an array of the minimal configuration that would cause no errors. Then that array will be used to call the actual load() method of the extension.

@cordoval
Copy link
Contributor Author

still it does not address the question, i was actually looking of an example with values, even if it is hypothetical it would help. I tried to use but i was lost:

something like this but with typical values:

[
   'a' => 'b',
   'c' => 'd',
]

or explaining what key and value are typically like
and also if different array configuration or nested or if values are directly parameters of the container etc

@matthiasnoback
Copy link
Collaborator

Ah, no, it is like in the examples of load(array(...)). It's the values that get passed in as values for the config tree of the extension.

@cordoval
Copy link
Contributor Author

which are like? That is what i say it is too abstract for the reader. Maybe adding an example of the first few typical values could prove very valuable so they can use this feature.

@matthiasnoback
Copy link
Collaborator

:) Well, when your config tree has a scalar node called "default_port" and it is required, then you can return array('default_port' => 4730) in getMinimalConfiguration() so that calling $this->load() will always work, even if you provide no argument.

You're right, there should be something about this in the README file...

@ghost
Copy link

ghost commented Jul 28, 2014

yeah it'd be nice to see an example

@matthiasnoback
Copy link
Collaborator

Closing this to clean the list of open issues. If anyone would like to supply an example, feel free to do so.

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

No branches or pull requests

2 participants