Code coverage report for src/stores/MarkdownSelectionStore.js

Statements: 100% (8 / 8)      Branches: 100% (0 / 0)      Functions: 100% (3 / 3)      Lines: 100% (8 / 8)      Ignored: none     

All files » src/stores/ » MarkdownSelectionStore.js
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 201 1   1   1 1       1       2       1  
var Reflux = require('reflux');
var MarkdownSelectionActions = require('../actions/MarkdownSelectionActions');
 
var MarkdownSelectionStore = Reflux.createStore({
  init: function() {
    this.listenTo(MarkdownSelectionActions.selectionSet, this.handleSelectionSet);
    this.listenTo(MarkdownSelectionActions.selectionCleared, this.handleSelectionCleared);
  },
 
  handleSelectionCleared: function() {
    this.trigger({type: 'clear'});
  },
 
  handleSelectionSet: function() {
    this.trigger({type: 'set'});
  }
});
 
module.exports = MarkdownSelectionStore;