score:1

You can use window.location.search API, just put following function into a JS file and import it where you need:

src/utils/query.js

   export function getQuery() {
      let b = window.location.search
        .slice(1)
        .split("&")
        .map(qStr => qStr.split("="))
        .reduce((acc, inc) => {
          acc[inc[0]] = inc[1];
          return acc;
        }, {});
        return b;
    }

and where you want to use it

import getQuery from './utils/query';
.
.
.
    let q = getQuery();
    if(q.lenght){
        let name = q['name']
        let id = q['id']
        let from = q['from']
    }
    //Or directly call it
    let name = getQuery()['name']
    let id = getQuery()['id']
    let from = getQuery()['from']


Related Query

More Query from same tag