From 45f45bf1b4112c4175b44e6013862932ec90a347 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Pierzcha=C5=82a?= Date: Wed, 17 Oct 2018 22:12:18 +0200 Subject: [PATCH] feat: move pretty-format from peer do deps (#39) ### Summary We could also make it an optional dependency and inline-require it inside debug (the only place we use it) but for now I decided to make it a regular dependency, because that's what it is, no point in making users install it directly. ### Test plan green CI --- README.md | 2 +- package.json | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 6e6b89d6..961d2ff4 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,7 @@ Open a Terminal in your project's folder and run: yarn add --dev react-native-testing-library ``` -This library has a peerDependencies listing for `react-test-renderer`, `pretty-format` and, of course, `react`. Make sure to install them too! +This library has a peerDependencies listing for `react-test-renderer` and, of course, `react`. Make sure to install them too! As you may have noticed, it's not tied to React Native at all – you can safely use it in your React components if you feel like not interacting directly with DOM. diff --git a/package.json b/package.json index 6adfeeaa..17c916b1 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,6 @@ "flow-bin": "^0.83.0", "jest": "^23.6.0", "metro-react-native-babel-preset": "^0.48.0", - "pretty-format": "^23.6.0", "react": "16.6.0-alpha.8af6728", "react-native": "^0.57.3", "react-test-renderer": "16.6.0-alpha.8af6728", @@ -31,8 +30,10 @@ "strip-ansi": "^5.0.0", "typescript": "^3.1.1" }, + "dependencies": { + "pretty-format": "^23.6.0" + }, "peerDependencies": { - "pretty-format": ">=20.0.0", "react": ">=16.0.0", "react-test-renderer": ">= 16.0.0" },