mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: deduplicates / unifies types for source maps across the code base Reviewed By: jeanlauliac Differential Revision: D4955924 fbshipit-source-id: 25cb71031dce835dd7d2bc1c27d6b20050906e81
27 lines
694 B
JavaScript
27 lines
694 B
JavaScript
/**
|
|
* Copyright (c) 2016-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.
|
|
*
|
|
* @flow
|
|
*/
|
|
'use strict';
|
|
|
|
import type {FBSourceMap, IndexMapSection, IndexMap} from '../../lib/SourceMap';
|
|
|
|
export type {FBSourceMap};
|
|
|
|
type CreateIndexMapOptions = {|
|
|
file?: string,
|
|
sections?: Array<IndexMapSection>
|
|
|};
|
|
|
|
exports.createIndexMap = (opts?: CreateIndexMapOptions): IndexMap => ({
|
|
version: 3,
|
|
file: opts && opts.file,
|
|
sections: opts && opts.sections || [],
|
|
});
|