Skip to content

Commit

Permalink
Move DraftFeatureFlags to stubs (facebookarchive#1278)
Browse files Browse the repository at this point in the history
**what is the change?:**
Moved 'DraftFeatureFlags' to 'stubs' directory, and make it export
'DraftFeatureFlags-core'.

**why make this change?:**
The 'DraftFeatureFlags' file is, *I think*, the last file which is out
of sync with our internal FB version of Draft. That is because we
actually use different flag configs within FB than the defaults for OS.

**test plan:**
`yarn install && yarn build && yarn test` and play with example files

**issue:**
issue facebookarchive#1244
  • Loading branch information
flarnie authored and colinjeanne committed Dec 22, 2017
1 parent 8b66aa6 commit 786f268
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 4 deletions.
21 changes: 21 additions & 0 deletions src/component/utils/DraftFeatureFlags-core.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/**
* Copyright 2013-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
* @providesModule DraftFeatureFlags-core
* @flow
*/

'use strict';

var DraftFeatureFlags = {
draft_accept_selection_after_refocus: false,
draft_killswitch_allow_nontextnodes: false,
draft_segmented_entities_behavior: false,
};

module.exports = DraftFeatureFlags;
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@

'use strict';

var DraftFeatureFlags = {
draft_killswitch_allow_nontextnodes: false,
draft_segmented_entities_behavior: false,
};
var DraftFeatureFlags = require('DraftFeatureFlags-core');

module.exports = DraftFeatureFlags;

0 comments on commit 786f268

Please sign in to comment.