Support Offline Usage by Making Monaco-Editor use Local Files #364
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
By default, a dependency of Mquery, @monaco-editor/react, reaches to a CDN for files. This commit makes it so that these files (from monaco-editor, a peerDependency) are accessible locally under
{URL}/monaco-vs/...
. This allows for offline usage of Mquery.Your checklist for this pull request
What is the current behaviour?
Mquery reaches out to a CDN (cdn.jsdelivr.net) for files necessary for the Monaco-Editor component to work.
What is the new behaviour?
Mquery grabs the files necessary for the Monaco-Editor component locally from
{URL}/monaco-vs/...
.Current → New Behavior: Network Activity
This image demonstrates network requests for editor files changing from the CDN to localhost.
Test plan
Use Mquery normally across each of these scenarios - witnessing the expected outcome.
Closing issues
Not related to any current issues.