diff --git a/package.json b/package.json index a3f68ee..7081adb 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "homepage": "https://github.com/react-navigation/react-navigation-web#readme", "dependencies": { "history": "^4.7.2", - "query-string": "^6.2.0" + "qs": "^6.7.0" }, "devDependencies": { "@babel/runtime": "^7.4.5", @@ -66,7 +66,8 @@ "react-native": "^0.55.4", "react-native-safe-area-context": "^0.3.5", "react-test-renderer": "16.3.1", - "release-it": "^7.6.1" + "release-it": "^7.6.1", + "@react-navigation/core": "*" }, "peerDependencies": { "@react-navigation/core": "^3.0.0-alpha.13", diff --git a/src/Link.js b/src/Link.js index 3ec19e0..bad4c8a 100644 --- a/src/Link.js +++ b/src/Link.js @@ -1,6 +1,7 @@ import React, { Component } from 'react'; import { withNavigation, NavigationActions } from '@react-navigation/core'; -import queryString from 'query-string'; +import queryString from 'qs'; + const getTopNavigation = navigation => { const parent = navigation.dangerouslyGetParent(); diff --git a/src/createBrowserApp.js b/src/createBrowserApp.js index 673e6e7..f1ce222 100644 --- a/src/createBrowserApp.js +++ b/src/createBrowserApp.js @@ -13,8 +13,7 @@ import { } from '@react-navigation/core'; import { SafeAreaProvider } from 'react-native-safe-area-context'; -/* eslint-disable import/no-commonjs */ -const queryString = require('query-string'); +import queryString from 'qs'; const getPathAndParamsFromLocation = location => { const path = encodeURI(location.pathname.substr(1)); diff --git a/yarn.lock b/yarn.lock index 9c07f8e..25aa102 100644 --- a/yarn.lock +++ b/yarn.lock @@ -614,6 +614,17 @@ node-fetch "^2.1.1" url-template "^2.0.8" + +"@react-navigation/core@*": + version "3.3.1" + resolved "https://registry.yarnpkg.com/@react-navigation/core/-/core-3.3.1.tgz#14021eff792a6e27ee407c867d454b25507efdf2" + integrity sha512-pvvnUPUe4Pf5hJ8+fAsRsuNaBT8kcxmBJkd9SsFA7aftvEnAIXL9mEanMJyhtUAw2s6nipqu4E+Mw1ToPhW6oA== + dependencies: + hoist-non-react-statics "^2.5.5" + path-to-regexp "^1.7.0" + query-string "^6.2.0" + react-is "^16.6.3" + "@react-navigation/core@^3.4.2": version "3.4.2" resolved "https://registry.yarnpkg.com/@react-navigation/core/-/core-3.4.2.tgz#bec563e94fde40fbab3730cdc97f22afbb2a1498" @@ -4181,6 +4192,12 @@ history@^4.7.2: value-equal "^0.4.0" warning "^3.0.0" + +hoist-non-react-statics@^2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-2.5.5.tgz#c5903cf409c0dfd908f388e619d86b9c1174cb47" + integrity sha512-rqcy4pJo55FTTLWt+bU8ukscqHeE/e9KWvsOW2b/a3afxQZhwkQdT1rPPCJ0rYXdj4vNcasY8zHTH+jF/qStxw== + hoist-non-react-statics@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.0.tgz#b09178f0122184fb95acf525daaecb4d8f45958b" @@ -4188,6 +4205,9 @@ hoist-non-react-statics@^3.3.0: dependencies: react-is "^16.7.0" + + + home-or-tmp@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz#e36c3f2d2cae7d746a857e38d18d5f32a7882db8" @@ -6776,6 +6796,11 @@ q@^1.4.1, q@^1.5.1: resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" integrity sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc= +qs@^6.7.0: + version "6.7.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.7.0.tgz#41dc1a015e3d581f1621776be31afb2876a9b1bc" + integrity sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ== + qs@~6.5.2: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" @@ -6791,11 +6816,12 @@ query-string@^5.0.1: strict-uri-encode "^1.0.0" query-string@^6.2.0: - version "6.2.0" - resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.2.0.tgz#468edeb542b7e0538f9f9b1aeb26f034f19c86e1" - integrity sha512-5wupExkIt8RYL4h/FE+WTg3JHk62e6fFPWtAZA9J5IWK1PfTfKkMS93HBUHcFpeYi9KsY5pFbh+ldvEyaz5MyA== + version "6.4.2" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.4.2.tgz#8be1dbd105306aebf86022144f575a29d516b713" + integrity sha512-DfJqAen17LfLA3rQ+H5S4uXphrF+ANU1lT2ijds4V/Tj4gZxA3gx5/tg1bz7kYCmwna7LyJNCYqO7jNRzo3aLw== dependencies: decode-uri-component "^0.2.0" + split-on-first "^1.0.0" strict-uri-encode "^2.0.0" query-string@^6.4.2: @@ -6869,6 +6895,12 @@ react-is@^16.3.1, react-is@^16.5.2: resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.5.2.tgz#e2a7b7c3f5d48062eb769fcb123505eb928722e3" integrity sha512-hSl7E6l25GTjNEZATqZIuWOgSnpXb3kD0DVCujmg46K5zLxsbiKaaT6VO9slkSBDPZfYs30lwfJwbOFOnoEnKQ== + +react-is@^16.6.3: + version "16.8.6" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz#5bbc1e2d29141c9fbdfed456343fe2bc430a6a16" + integrity sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA== + react-is@^16.7.0, react-is@^16.8.6: version "16.8.6" resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz#5bbc1e2d29141c9fbdfed456343fe2bc430a6a16" @@ -7779,10 +7811,13 @@ spdx-license-ids@^3.0.0: integrity sha512-TfOfPcYGBB5sDuPn3deByxPhmfegAhpDYKSOXZQN81Oyrrif8ZCodOLzK3AesELnCx03kikhyDwh0pfvvQvF8w== split-on-first@^1.0.0: + + version "1.1.0" resolved "https://registry.yarnpkg.com/split-on-first/-/split-on-first-1.1.0.tgz#f610afeee3b12bce1d0c30425e76398b78249a5f" integrity sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw== + split-string@^3.0.1, split-string@^3.0.2: version "3.1.0" resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2"