fix compatibility: must use "require" for babel/polyfill

This commit is contained in:
Mahdi Dibaiee 2015-09-07 19:28:21 +04:30
parent b3c0197e03
commit 21fcd12f6d
5 changed files with 3 additions and 9 deletions

View File

@ -34251,7 +34251,6 @@ exports.createDirectory = createDirectory;
var remove = _asyncToGenerator(function* (file, deep) { var remove = _asyncToGenerator(function* (file, deep) {
var parent = yield root(); var parent = yield root();
console.log(deep);
return parent[deep ? 'removeDeep' : 'remove'](file); return parent[deep ? 'removeDeep' : 'remove'](file);
}); });
@ -34989,7 +34988,6 @@ var Menu = (function (_Component) {
var els = items.map(function (item, index) { var els = items.map(function (item, index) {
var enabled = typeof item.enabled === 'function' ? item.enabled() : true; var enabled = typeof item.enabled === 'function' ? item.enabled() : true;
console.log(enabled);
var className = enabled ? '' : 'disabled'; var className = enabled ? '' : 'disabled';
return _react2['default'].createElement( return _react2['default'].createElement(
@ -35799,8 +35797,6 @@ module.exports = exports['default'];
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
require('babel/polyfill');
var _react = require('react'); var _react = require('react');
var _react2 = _interopRequireDefault(_react); var _react2 = _interopRequireDefault(_react);
@ -35817,6 +35813,8 @@ var _reactRedux = require('react-redux');
require('./activities'); require('./activities');
require('babel/polyfill');
var wrapper = document.getElementById('wrapper'); var wrapper = document.getElementById('wrapper');
_react2['default'].render(_react2['default'].createElement( _react2['default'].render(_react2['default'].createElement(
_reactRedux.Provider, _reactRedux.Provider,
@ -36700,7 +36698,6 @@ exports['default'] = function () {
var _listener = _step2$value.listener; var _listener = _step2$value.listener;
var _ev = _step2$value.ev; var _ev = _step2$value.ev;
console.log(_item, _listener);
_item.removeEventListener(_ev, _listener); _item.removeEventListener(_ev, _listener);
} }
} catch (err) { } catch (err) {

View File

@ -80,7 +80,6 @@ export async function createDirectory(...args) {
export async function remove(file, deep) { export async function remove(file, deep) {
let parent = await root(); let parent = await root();
console.log(deep);
return parent[deep ? 'removeDeep' : 'remove'](file); return parent[deep ? 'removeDeep' : 'remove'](file);
} }

View File

@ -9,7 +9,6 @@ export default class Menu extends Component {
let els = items.map((item, index) => { let els = items.map((item, index) => {
let enabled = typeof item.enabled === 'function' ? item.enabled() : true let enabled = typeof item.enabled === 'function' ? item.enabled() : true
console.log(enabled);
let className = enabled ? '' : 'disabled'; let className = enabled ? '' : 'disabled';
return <li key={index} className={className} onClick={item.action.bind(this)}>{item.name}</li> return <li key={index} className={className} onClick={item.action.bind(this)}>{item.name}</li>

View File

@ -1,4 +1,4 @@
import 'babel/polyfill'; require('babel/polyfill');
import React from 'react'; import React from 'react';
import Root from 'components/root'; import Root from 'components/root';
import store from 'store'; import store from 'store';

View File

@ -49,7 +49,6 @@ export default function() {
localStorage.setItem('tourRan', 'true'); localStorage.setItem('tourRan', 'true');
for (let {item, listener, ev} of listeners) { for (let {item, listener, ev} of listeners) {
console.log(item, listener);
item.removeEventListener(ev, listener); item.removeEventListener(ev, listener);
} }
} }