deck.js-codemirror icon indicating copy to clipboard operation
deck.js-codemirror copied to clipboard

select code evaluator depending on mode

Open dvberkel opened this issue 12 years ago • 0 comments

I have come to rely on running code samples in presentations. Unfortunately currently only evaluating JavaScript code is supported.

This change allows different evaluators to be configured by setting appropriate options. E.g.

$.deck.defaults.evaluatorFactoryFor['ruby'] = function(editor, output){
  // retrieve result of execution of code via delegation to a server
  output.html(result);
}

Which would enable 'running' Ruby code.

dvberkel avatar Jun 19 '13 11:06 dvberkel