Skip to content

Commit

Permalink
[fix] Only inject ResponderEventPlugin client-side
Browse files Browse the repository at this point in the history
Close #1434
Fix #1433
  • Loading branch information
marnusw authored and necolas committed Sep 30, 2019
1 parent 6ce88e6 commit 250ee3c
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions packages/react-native-web/src/exports/createElement/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,18 @@
*/

import AccessibilityUtil from '../../modules/AccessibilityUtil';
import { canUseDOM } from 'fbjs/lib/ExecutionEnvironment';
import createDOMProps from '../../modules/createDOMProps';
import { injectEventPluginsByName } from 'react-dom/unstable-native-dependencies';
import normalizeNativeEvent from '../../modules/normalizeNativeEvent';
import React from 'react';
import ResponderEventPlugin from '../../modules/ResponderEventPlugin';

injectEventPluginsByName({
ResponderEventPlugin
});
if (canUseDOM) {
injectEventPluginsByName({
ResponderEventPlugin
});
}

const isModifiedEvent = event =>
!!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey);
Expand Down

0 comments on commit 250ee3c

Please sign in to comment.