javascript - Issues Integrating ACE Editor with Keystonejs App -


it says here(http://ace.c9.io/#nav=embedding) copy 1 of src* subdirectories somewhere project have put in mykeystoneapp/public/js(my default home mykeystoneapp/public)

here errors get:

1.uncaught typeerror: $.cookie not function(ui.js:8)

2.uncaught error: missed anonymous define() module: function …(require.js:141) http://requirejs.org/docs/errors.html#mismatch

here jade code:

script(src='/js/ace/demo/kitchen-sink/require.js') script.   require.config({paths: {ace: "/js/ace/build/src"}});   define('testace', ['ace/ace'],   function(ace, langtools) {     console.log("this testace module");     var editor = ace.edit("editor_container");     editor.settheme('eclipse');     editor.session.setmode('javascript');     require(["/js/ace/lib/ace/requirejs/text!src/ace"], function(e){       editor.setvalue(e);     })   });   require(['testace']); 

secondly if put debugger in eventemitter(https://github.com/ajaxorg/ace-builds/blob/master/src/ace.js#l3300) can see it’s reaching eventemitter._dispatchevent eventname=‘changemode’ returns without operation there no !listeners or defaulthandler

editor.session.setmode('javascript'); wrong, should editor.session.setmode('ace/mode/javascript'); instead. same theme supposed ace/theme/eclipse.

error in ui.js not related ace, since ace doesn't have file named ui.


Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -