forked from facebook/react-native
-
Notifications
You must be signed in to change notification settings - Fork 146
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create shared consts module for scripts
Summary: Tidy up, removes risk of breakage when relocating inner modules. Changelog: [Internal] Reviewed By: lunaleaps Differential Revision: D53813025 fbshipit-source-id: 43dc4a57191363546d6858cff311e260d416192f
- Loading branch information
1 parent
a80674f
commit 80ec096
Showing
14 changed files
with
64 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/** | ||
* Copyright (c) Meta Platforms, Inc. and affiliates. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
* | ||
* @flow strict | ||
* @format | ||
* @oncall react_native | ||
*/ | ||
|
||
const path = require('path'); | ||
|
||
/** | ||
* The absolute path to the repo root. | ||
*/ | ||
const REPO_ROOT /*: string */ = path.resolve(__dirname, '..'); | ||
|
||
/** | ||
* The absolute path to the packages directory (note: this directory alone may | ||
* not match the "workspaces" config in package.json). | ||
*/ | ||
const PACKAGES_DIR /*: string */ = path.join(REPO_ROOT, 'packages'); | ||
|
||
/** | ||
* The absolute path to the repo scripts directory. | ||
*/ | ||
const SCRIPTS_DIR /*: string */ = path.join(REPO_ROOT, 'scripts'); | ||
|
||
/** | ||
* The absolute path to the react-native package. | ||
*/ | ||
const REACT_NATIVE_PACKAGE_DIR /*: string */ = path.join( | ||
REPO_ROOT, | ||
'packages', | ||
'react-native', | ||
); | ||
|
||
module.exports = { | ||
PACKAGES_DIR, | ||
REACT_NATIVE_PACKAGE_DIR, | ||
REPO_ROOT, | ||
SCRIPTS_DIR, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters