-
1. Re: Change ctrl shift / from html comment to cfml comment
Peter Flynn (Adobe) Sep 28, 2014 5:10 PM (in response to wannab0133)You can write an extension that defines a new language, maps the .cfml file extension to it, and defines "<!---" as the preferred block-comment style. (The linked documentation refers to "Brackets," which is just the open-source flavor of Edge Code -- the instructions should work the same for both). Because Brackets / Edge Code normally treats .cfml as plain HTML, you'll also have to write some code in your extension to remove .cfml from the list of HTML-language file extensions before you can add it to your new CFML language. Overall, your extension would look something like this:
define(function (require, exports, module) {
var LanguageManager = brackets.getModule("language/LanguageManager");
LanguageManager.getLanguage("html").removeFileExtension("cfml");
LanguageManager.defineLanguage("cfml", {
name: "CFML",
mode: ["htmlmixed", "text/x-brackets-html"],
fileExtensions: ["cfml"],
blockComment: ["<!---", "-->"]
});
});Hope that helps!
- Peter


