feat: update docs bases on cancelled prepare-2 PR (#335)

* Adapt docs changes from `prepare-2` branch

* WIP

* Removed unused `printUnsafeWarning` function

# Conflicts:
#	src/helpers/errors.js

* Code review changes
This commit is contained in:
Maciej Jastrzebski
2020-05-19 16:58:27 +02:00
committed by Michał Pierzchała
parent 9fc83fec60
commit 01bc0ee2b4
2 changed files with 12 additions and 25 deletions
-14
View File
@@ -39,20 +39,6 @@ export function printDeprecationWarning(functionName: string) {
warned[functionName] = true;
}
export function printUnsafeWarning(functionName: string) {
if (warned[functionName]) {
return;
}
console.warn(`
Deprecation Warning:
${functionName} is not recommended for use and has been renamed to UNSAFE_${functionName}.
In react-native-testing-library 2.x only the UNSAFE_${functionName} name will work.
`);
warned[functionName] = true;
}
export function throwRemovedFunctionError(
functionName: string,
docsRef: string