Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var React = require('react'),
_ = require('lodash'),
$ = require('jquery'),
ComponentTree = require('react-component-tree'),
FlatrisStatePreview = require('./FlatrisStatePreview.jsx');
class FlatrisStatePersistor extends ComponentTree.Component {
/**
* Persist Flatris state with local storage.
*/
constructor() {
super();
this.onUnload = this.onUnload.bind(this);
this.children = {
flatrisStatePreview: function() {
return {
component: FlatrisStatePreview
};
}
};
}