          (skewer--save-point #'skewer-eval-last-expression))
       (cl-destructuring-bind (string start end) (skewer-get-last-expression)
         (skewer-flash-region start end)
-        (skewer-eval (if pprint
-                         (concat "skewer.log("
-                                 ;; remove tailing semicolon
-                                 (let ((trimmed (trim-string string)))
-                                   (if (equal (substring trimmed -1 nil) ";")
-                                       (substring trimmed 0 -1)
-                                     trimmed)) ");")
-                       string)
-                     #'skewer-post-minibuffer)))))
+        (skewer-eval string #'skewer-post-minibuffer)))))
+
+(defun skewer-pprint-eval-last-expression ()
+  (interactive)
+  (if js2-mode-buffer-dirty-p
+      (js2-mode-wait-for-parse
+       (skewer--save-point #'skewer-pprint-eval-last-expression))
+    (cl-destructuring-bind (string start end) (skewer-get-last-expression)
+      (skewer-flash-region start end)
+      (skewer-eval string #'skewer-post-pprint :verbose t)
+      (display-buffer (get-buffer-create skewer-result-buffer)))))
+
+(defun skewer-json-format ()
+  "Simple pretty print json buffer."
+  (interactive)
+  (beginning-of-buffer)
+  (replace-string "," ",\n")
+  (js2-mode)
+  (mark-whole-buffer)
+  (indent-for-tab-command)
+  (js2-reparse))
+
+(defun skewer-post-pprint (result)
+  (if (not (skewer-success-p result))
+      (skewer-post-minibuffer result)
+    (let ((value (cdr (assoc 'value result))))
+      (with-current-buffer (get-buffer-create skewer-result-buffer)
+        (erase-buffer)
+        (insert value)
+        (insert "\n")
+        (skewer-json-format)))))
 
 (defun skewer-get-defun ()
   "Return the toplevel JavaScript expression around the point as

;; `skewer-mode'.

;;  * C-x C-e -- `skewer-eval-last-expression'
;;  * C-c C-p -- `skewer-eval-and-print-last-expression'
;;  * C-M-x   -- `skewer-eval-defun'
;;  * C-c C-k -- `skewer-load-buffer'


            (end (js2-node-abs-end node)))
        (list (buffer-substring-no-properties start end) start end)))))

(defun skewer-eval-last-expression (&optional prefix)
  "Evaluate the JavaScript expression before the point in the
waiting browser. If invoked with a prefix argument, insert the
result into the current buffer."
