Closed awunnenb closed 5 years ago
You're expected to pick a dialect (via a mime type string). But I agree it's not very useful for the mode to not recognize any keywords when you don't—attached patch fixes that.
thank you very much. Where can i set the mime-type? In markup or by Code/Config? I can't find any code-example to set mime-type-string for special sql syntax highlighting.
Instead of "sql"
, you set the mode
option to something like "text/x-pgsql"
.
@marijnh I want to set the syntax highlighting of pyhton3, just write it as text/x-python?
mode: sql fails, no highlighting all other modes works fine.
codeMirrorOptions = { mode: 'sql', lineNumbers: true, theme: 'material' };