Files
ohif-viewer/platform/viewer/src/customHooks/useQuery.js
T

12 lines
233 B
JavaScript

import { useLocation } from 'react-router-dom';
/**
* hook that builds on useLocation to parse
* the query string for you.
*
* @name useQuery
*/
export default function() {
return new URLSearchParams(useLocation().search);
}