Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ace Editor Plugin for MVC Razor syntax [closed]

Tags:

ace-editor

How i can create a plugin for ACE Editor to support Razor syntax. Ace Home Page: http://ace.c9.io

like image 934
mehr Avatar asked Feb 06 '14 07:02

mehr


1 Answers

Here is a started implementation of Razor syntax highlighting in ACE. All credits goes to Andrey Shchekin a member of Stack Overflow.

Download his branch of the ACE from GIT. In Node.JS command prompt go to the directory and do the following:

  1. npm install
  2. node Makefile.dryice.js full

Then copy the src folder that you want to work with and configure ace like this.

var editor = ace.edit("editor");
editor.setTheme("ace/theme/chrome_razor"); //Razor CSS
editor.getSession().setMode("ace/mode/razor"); //Razor Syntax!!!

A sample of how it looks like

enter image description here

Thank you so much to Andrey for starting this off hopefully it will get a boost now more people can tinker with it.

like image 182
Piotr Kula Avatar answered Sep 24 '22 00:09

Piotr Kula