Skip to content

Add ace-modes to javascript manifest, fixes #7513

Matthias Käppler requested to merge github/fork/Razer6/fix_ace_modes into master

Created by: Razer6

What does this MR do?

This PR adds most of the modes of ace editor to the javascript manifest. With this PR, there is syntax highlighting while editing a file. I've included all modes which file size is less than 120k.

Additionally it adds syntax highlighting, when creating a new snippet or file via web interface. The mode is determined on the current entered filename and tracks if the user changes it.

Are there points in the code the reviewer needs to double check?

Setting asset path of ace modes is removed, since this is now served directly through the rails asset pipeline.

Why was this MR needed?

Currently, when opening a file (e.g. a markdown), ace editor tries to load the mode file. Since it's not in the manifest, a 404 error is raised behind the scenes, and no syntax highlighting is available.

What are the relevant issue numbers / Feature requests?

This PR fixes

/cc @cirosantilli

Screenshots (If appropiate)

screenshot 2014-08-18 12 24 15

screenshot 2014-08-18 12 26 02

create_file

Merge request reports

Loading