-
Notifications
You must be signed in to change notification settings - Fork 26
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
feat(config): add config service to manage the application #65
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice addition. A few small changes are needed.
src/demo-app/app/module.ts
Outdated
@@ -34,6 +36,10 @@ export function languageLoader(http: Http) { | |||
IgoModule.forRoot() | |||
], | |||
providers: [ | |||
provideConfigOptions({ | |||
default: environment.igo, | |||
jsonPathFile: './config/config.json' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be "jsonFilePath" or simply "path"
@@ -0,0 +1,4 @@ | |||
export interface ConfigOptions { | |||
default?: {[key: string]: any}, | |||
jsonPathFile?: string |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment above
import { Http } from '@angular/http'; | ||
import { Observable } from 'rxjs/Rx'; | ||
|
||
import { ObjectUtils } from "../../utils"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Single quotes
|
||
constructor(private jsonp: Jsonp, | ||
@Inject(SEARCH_SOURCE_OPTIONS) | ||
private options: SearchSourceOptions) { | ||
private options: SearchSourceOptions, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should search options such as "limit" be configurable in the service?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes and several other options in other services.
No description provided.