-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Fixed some follow ups after restructuring and issues around generator-theia #310
Changes from 3 commits
da86895
0f8189c
b87dccd
e70a143
64c9ddc
29b824c
d2cf122
2481dfe
52a0dfe
fef2693
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -51,7 +51,7 @@ export abstract class AbstractGenerator { | |
return `Promise.resolve(${invocation})`; | ||
} | ||
return invocation; | ||
}).map(statement => `.then(function () { return ${statement}.then(load) })`); | ||
}).map(statement => ` .then(function () { return ${statement}.then(load) })`); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What is this change for? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. to fix indentation in the generated source files: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes thx for that! I had run into trouble with it |
||
return os.EOL + lines.join(os.EOL); | ||
} | ||
|
||
|
@@ -60,4 +60,20 @@ export abstract class AbstractGenerator { | |
return copyright ? copyright + os.EOL : ''; | ||
} | ||
|
||
protected isWeb(): boolean { | ||
return this.model.target === 'web'; | ||
} | ||
|
||
protected isElectron(): boolean { | ||
return this.model.target === 'electron'; | ||
} | ||
|
||
protected ifWeb(value: string, defaultValue: string = '') { | ||
return this.isWeb() ? value : defaultValue; | ||
} | ||
|
||
protected ifElectron(value: string, defaultValue: string = '') { | ||
return this.isElectron() ? value : defaultValue; | ||
} | ||
|
||
} |
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.
We should update it to say that now the endpoints with /services/* are served by the webpack dev server