Big update!Introducing GitHub Bot Commands. Learn more
Socket
Log inDemoInstall

prepend-http

Package Overview
Dependencies
0
Maintainers
1
Versions
9
Issues
File Explorer

Advanced tools

prepend-http

Prepend `https://` to humanized URLs like sindresorhus.com and localhost

    4.0.0latest
    Github

Version published
Maintainers
1
Weekly downloads
15,981,933
increased by9.21%

Weekly downloads

Readme

Source

prepend-http

Prepend https:// to humanized URLs like sindresorhus.com and localhost

Install

$ npm install prepend-http

Usage

import prependHttp from 'prepend-http'; prependHttp('sindresorhus.com'); //=> 'https://sindresorhus.com' prependHttp('localhost', {https: false}); //=> 'http://localhost' prependHttp('https://sindresorhus.com'); //=> 'https://sindresorhus.com'

API

prependHttp(url, options?)

url

Type: string

The URL to prepend https:// to.

options

Type: object

https

Type: boolean
Default: true

Prepend https:// instead of http://.


Get professional support for this package with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.

Keywords

FAQs

What is prepend-http?

Prepend `https://` to humanized URLs like sindresorhus.com and localhost

Is prepend-http popular?

The npm package prepend-http receives a total of 15,282,304 weekly downloads. As such, prepend-http popularity was classified as popular.

Is prepend-http well maintained?

We found that prepend-http 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.

Last updated on 09 Aug 2021

Did you know?

Socket installs a Github app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install Socket
Socket[email protected]

Product

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc