You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 23, 2020. It is now read-only.
As the language modes page shows, for the C++ language CodeMirror only has a C-like mode, and it seems that to make a proper configuration for C++, we have to
set the name of the mode to 'clike' to load the appropriate mode file (clike.js in this case), and
set the MIME type to text/x-c++src, as suggested at the bottom of this page, since the clike mode is not C++-specific.
And how can I achieve that without hard-coding something into the template file?
mode: string|object
The mode to use. It may be a string, which either simply names the mode or is a MIME type associated with the mode. Alternatively, it may be an object containing configuration options for the mode, with a name property that names the mode (for example {name: "javascript", json: true})
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
As the language modes page shows, for the C++ language CodeMirror only has a C-like mode, and it seems that to make a proper configuration for C++, we have to
clike.js
in this case), andtext/x-c++src
, as suggested at the bottom of this page, since the clike mode is not C++-specific.And how can I achieve that without hard-coding something into the template file?
For reference, the CodeMirror manual says
The text was updated successfully, but these errors were encountered: