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

Add streaming type definitions #121

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

lxsmnsyc
Copy link
Member

No description provided.

@lxsmnsyc lxsmnsyc marked this pull request as draft September 27, 2022 13:16
editor: monaco.editor.ICodeEditor,
): Promise<void> {
if (LOADED) {
return;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this changes semantics... I thought we needed to wireTmGrammars to every new editor instance (i.e. toggling output code tab)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't recall having to wire it all the time, but if it does cause issues then we can remove the guard

'source.css': 'css',
'source.js': 'jsx',
// 'source.js': 'javascript',
'source.js.jsx': 'jsx',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this used? Edit: nvm, I see above, but why not just make 'javascript' also map to source.tsx?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TBF we can just remove it. jsx and tsx has different grammars.

function createRegistry(): Registry {
return new Registry({
getGrammarDefinition: async (scopeName) => {
console.log(scopeName);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah I forgot to remove this 🤣

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

Successfully merging this pull request may close these issues.

None yet

2 participants