<commit_before>var RtodApp = React.createClass({displayName: 'RtodApp',
  word: RtodDico.getRandomWord(),
  getInitialState: function() {
    return {
      aim: this.word,
      remaining: this.word
    };
  },
  onKeyDown: function(e) {
    if (e.target.value.length > 0 && this.word.indexOf(e.target.value) === 0) {
      this.word = this.word.substring(e.target.value.length, this.word.length);
      this.setState({
        remaining: this.word
      });
      if (this.word.length === 0) {
        this.word = RtodDico.getRandomWord();
        this.setState({
          aim: this.word,
          remaining: this.word
        });
      }
    }
    e.target.value = '';
  },
  render: function() {
    return (
      React.createElement('div', {className: 'RtodApp'},
        React.createElement('h1', null, 'The React Type of the Dead'),
        React.createElement('div', {
          dangerouslySetInnerHTML: {
            __html: this.state.aim
          }
        }),
        React.createElement('div', {
          dangerouslySetInnerHTML: {
            __html: this.state.remaining
          }
        }),
        React.createElement('input', {
          onKeyUp: this.onKeyDown
        })
      )
    );
  }
});
React.render(
  React.createElement(RtodApp, null),
  document.getElementById('content')
);<commit_msg>RtodScore use<commit_after>var RtodApp = React.createClass({displayName: 'RtodApp',
  word: RtodDico.getRandomWord(),
  getInitialState: function() {
    return {
      aim: this.word,
      remaining: this.word
    };
  },
  onKeyDown: function(e) {
    if (e.target.value.length > 0 && this.word.indexOf(e.target.value) === 0) {
      RtodScore.increment();
      this.word = this.word.substring(e.target.value.length, this.word.length);
      this.setState({
        remaining: this.word
      });
      if (this.word.length === 0) {
        RtodScore.wordComplete();
        this.word = RtodDico.getRandomWord();
        this.setState({
          aim: this.word,
          remaining: this.word
        });
      }
    }
    else {
      RtodScore.decrement();
    }
    e.target.value = '';
  },
  render: function() {
    return (
      React.createElement('div', {className: 'RtodApp'},
        React.createElement('h1', null, 'The React Typing of the Dead'),
        React.createElement(RtodScore.getReactElement()),
        React.createElement('div', {
          dangerouslySetInnerHTML: {
            __html: this.state.aim
          }
        }),
        React.createElement('div', {
          dangerouslySetInnerHTML: {
            __html: this.state.remaining
          }
        }),
        React.createElement('input', {
          onKeyUp: this.onKeyDown
        })
      )
    );
  }
});

React.render(
  React.createElement(RtodApp, null),
  document.getElementById('content')
);
{'fraction_non_alphanumeric': 0.14574468085106382, 'fraction_numerical': 0.0028368794326241137, 'mean_word_length': 2.1102535832414553, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '1136760', 'n_tokens_mistral': 881, 'n_tokens_neox': 900, 'n_words': 138}