mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 20:52:56 +01:00
Small tweaks
This commit is contained in:
parent
577cfae1cf
commit
2a73aeb3a6
1 changed files with 3 additions and 2 deletions
|
|
@ -76,7 +76,7 @@ interface IMonacoEditorWebpackPluginOpts {
|
|||
languages?: EditorLanguage[];
|
||||
|
||||
/**
|
||||
* customer languages which feature definition
|
||||
* Custom languages (outside of the ones shipped with the `monaco-editor`).
|
||||
*/
|
||||
customLanguages?: IFeatureDefinition[];
|
||||
|
||||
|
|
@ -114,9 +114,10 @@ class MonacoEditorWebpackPlugin implements webpack.Plugin {
|
|||
|
||||
constructor(options: IMonacoEditorWebpackPluginOpts = {}) {
|
||||
const languages = options.languages || Object.keys(languagesById);
|
||||
const customLanguages = options.customLanguages || [];
|
||||
const features = getFeaturesIds(options.features || []);
|
||||
this.options = {
|
||||
languages: coalesce(languages.map(id => languagesById[id])).concat(options.customLanguages || []),
|
||||
languages: coalesce(languages.map(id => languagesById[id])).concat(customLanguages),
|
||||
features: coalesce(features.map(id => featuresById[id])),
|
||||
filename: options.filename || "[name].worker.js",
|
||||
publicPath: options.publicPath || '',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue