mirror of
https://github.com/status-im/react-native.git
synced 2025-02-26 16:10:58 +00:00
Merge pull request #1384 from dsibiski/cli-package-name-validation
[CLI] Validation check for "React" package name
This commit is contained in:
commit
68718fd3bc
9
react-native-cli/index.js
vendored
9
react-native-cli/index.js
vendored
@ -65,6 +65,15 @@ function validatePackageName(name) {
|
||||
);
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
if (name === 'React') {
|
||||
console.error(
|
||||
'"%s" is not a valid name for a project. Please do not use the ' +
|
||||
'reserved word "React".',
|
||||
name
|
||||
);
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
function init(name) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user