Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
current-url
Advanced tools
Get the current URL isomorphically.
yarn add current-url
In the browser call the function with no arguments:
import { currentUrl } from 'current-url';
currentUrl();
On the server call the function with a Node HTTP request object as the first argument:
import { currentUrl } from 'current-url';
currentUrl(req);
// Ignore proxies
currentUrl(req, { ignoreProxies: true });
In both cases the function returns a URL
object.
ignoreProxies
Type: object
Default: false
By default, the currentUrl
function will take into account potential URL
rewrites made by proxies, load balancers, etc. along the way (as long as these
append special HTTP headers to the request). Use this option to disable that
behaviour.
FAQs
Get the current URL isomorphically.
The npm package current-url receives a total of 293 weekly downloads. As such, current-url popularity was classified as not popular.
We found that current-url 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
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.