Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

shurley

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

shurley - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

esm/mod.js

52

package.json
{
"module": "./esm/mod.js",
"main": "./script/mod.js",
"types": "./types/mod.d.ts",
"name": "shurley",
"version": "1.0.1",
"version": "1.0.2",
"description": "Validate or fix URLs from user input. People make mistakes!",
"main": "index.js",
"license": "ISC",
"author": "Bruno Bernardino <me@brunobernardino.com>",
"repository": {

@@ -10,29 +14,25 @@ "type": "git",

},
"bugs": {
"url": "https://github.com/BrunoBernardino/shurley/issues"
},
"exports": {
".": {
"import": {
"types": "./types/mod.d.ts",
"default": "./esm/mod.js"
},
"require": {
"types": "./types/mod.d.ts",
"default": "./script/mod.js"
}
}
},
"scripts": {
"lint": "eslint .",
"pretty": "prettier --write '*.{js,ts,json}'",
"pretty/test": "prettier --check '*.{js,ts,json}'",
"test": "mocha",
"test/ci": "npm run pretty/test && npm run lint && npm test"
"test": "node test_runner.js"
},
"keywords": [
"url",
"fix",
"parser",
"validator",
"user",
"input",
"url",
"fixer",
"url",
"parser",
"lax"
],
"author": "Bruno Bernardino <me@brunobernardino.com>",
"license": "ISC",
"devDependencies": {
"eslint": "6.8.0",
"mocha": "7.1.0",
"prettier": "1.19.1"
"@types/node": "^18.11.9",
"chalk": "^4.1.2",
"@deno/shim-deno": "~0.11.0"
}
}
}

@@ -23,10 +23,22 @@ # Shurley

### Deno
```ts
import shurley from 'https://deno.land/x/shurley@1.0.2/mod.ts';
const parsedUrl = shurley.parse('example.com');
console.log(parsedUrl); // Outputs 'https://example.com'
```
### Node/NPM
```bash
npm install --save shurley
npm install --save-exact shurley
```
```js
const shurley = require('shurley');
const shurley = require('shurley'); // or import shurley from 'shurley';
const parsedUrl = shurley.parse('/example.com');
const parsedUrl = shurley.parse('example.com');

@@ -38,7 +50,7 @@ console.log(parsedUrl); // Outputs 'https://example.com'

Requires `deno`.
```bash
npm install # installs dependencies
npm test # runs mocha
npm run lint # runs eslint
npm run pretty # runs prettier
make format
make test
```

@@ -48,2 +60,2 @@

Update the version, run tests, then just run `npm publish`.
Just run `make publish VERSION=x.y.z`, then commit + push.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc