forked from mirrors/org-mode
ob-js: Fix error when code block ends with a comment
* lisp/ob-js.el (org-babel-js-function-wrapper): Isolate body within wrapper. Reported-by: Compro Prasad <comproprasad@gmail.com> <http://permalink.gmane.org/gmane.emacs.orgmode/110390>
This commit is contained in:
parent
0bdf18befd
commit
0dd024aa92
|
@ -55,7 +55,7 @@
|
||||||
:type 'string)
|
:type 'string)
|
||||||
|
|
||||||
(defvar org-babel-js-function-wrapper
|
(defvar org-babel-js-function-wrapper
|
||||||
"require('sys').print(require('sys').inspect(function(){%s}()));"
|
"require('sys').print(require('sys').inspect(function(){\n%s\n}()));"
|
||||||
"Javascript code to print value of body.")
|
"Javascript code to print value of body.")
|
||||||
|
|
||||||
(defun org-babel-execute:js (body params)
|
(defun org-babel-execute:js (body params)
|
||||||
|
|
Loading…
Reference in a new issue