
Security News
Open Source CAI Framework Handles Pen Testing Tasks up to 3,600× Faster Than Humans
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.
query-extractor
Advanced tools
A simple module to get query parameters from a url
Require
var query = require('query-extractor');
Get all query parameters and their values in an object
query.getAll("https://awesomewebsite.com?name=canon&place=India");
Output
{ name: 'canon', place: 'India' }
Get the value for a specific key in query string
query.get("https://awesomewebsite.com?name=canon&place=India", "name");
Output
canon
The URL in function is optional, If you want it to use the URL of current page than pass null
instead and it'll use URL of current page
It uses window.location.href to get URL of current page.
If the specified key doesn't exists in query string than it returns null
.
If the specified key doesn't has any value than it returns ```''````.
FAQs
A simple module to extract query parameters from URL
We found that query-extractor demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.