<commit_before>/*jslint indent: 2, nomen: true, maxlen: 100, vars: true, white: true, plusplus: true, evil: true, es5:true  */
/*global require, exports, Backbone, EJS, $, window, ace, jqconsole, handler, help, location*/
/*global templateEngine*/

(function() {
  "use strict";
  window.shellView = Backbone.View.extend({
    resizing: false,

    el: '#content',

    template: templateEngine.createTemplate("shellView.ejs"),

    render: function() {
      $(this.el).html(this.template.render({}));

      this.replShell();

      $("#shell_workspace").trigger("resize", [ 150 ]);

      this.resize();

      // evil: the resize event is globally bound to window, but there is
      // no elegant alternative... (is there?)
      var self = this;
      $(window).resize(function () {
        self.resize();
      });

      return this;
    },

    resize: function () {
      // prevent endless recursion
      if (! this.resizing) {
        this.resizing = true;
        var windowHeight = $(window).height() - 250;<commit_msg>enabled pretty printing in js shell by default<commit_after>/*jslint indent: 2, nomen: true, maxlen: 100, vars: true, white: true, plusplus: true, evil: true, es5:true  */
/*global require, exports, Backbone, EJS, $, window, ace, jqconsole, handler, help, location*/
/*global templateEngine*/

(function() {
  "use strict";
  window.shellView = Backbone.View.extend({
    resizing: false,

    el: '#content',

    template: templateEngine.createTemplate("shellView.ejs"),

    render: function() {
      $(this.el).html(this.template.render({}));

      this.replShell();

      $("#shell_workspace").trigger("resize", [ 150 ]);

      this.resize();

      // evil: the resize event is globally bound to window, but there is
      // no elegant alternative... (is there?)
      var self = this;
      $(window).resize(function () {
        self.resize();
      });

      this.executeJs("start_pretty_print()");

      return this;
    },

    resize: function () {
      // prevent endless recursion
      if (! this.resizing) {
        this.resizing = true;
        var windowHeight = $(window).height() - 250;
{'fraction_non_alphanumeric': 0.15735567970204842, 'fraction_numerical': 0.010242085661080074, 'mean_word_length': 2.8170515097690942, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4665646', 'n_tokens_mistral': 672, 'n_tokens_neox': 624, 'n_words': 175}