mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Add a comment about why the string is split up. For future readers of this file.
This commit is contained in:
@@ -30,6 +30,9 @@ function deprecated(fnName, newModule, ctx, fn) {
|
||||
var newFn = function() {
|
||||
warning(
|
||||
warned,
|
||||
// Require examples in this string must be split to prevent React's
|
||||
// build tools from mistaking them for real requires.
|
||||
// Otherwise the build tools will attempt to build a '%s' module.
|
||||
'`require' + '("react").%s` is deprecated. Please use `require' + '("%s").%s` ' +
|
||||
'instead.',
|
||||
fnName,
|
||||
|
||||
Reference in New Issue
Block a user