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

reges

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

reges - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

test/charset.js

26

lib/reges.js

@@ -6,14 +6,10 @@ /*

// exports.url = /[a-zA-z]+:\/\/[^\s]*/;
exports.url = /^(http|https|ftp)+:\/\/\S+/;
exports.url = /^(http|https|ftp|)+:\/\/\S+/;
exports.http = /^http:\/\/\S+/;
exports.https = /^http:\/\/\S+/;
exports.https = /^https:\/\/\S+/;
exports.email = /\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/;
// exports.username = /^[a-zA-Z][a-zA-Z0-9_]{4,15}$/;
exports.username = /^[a-z0-9_-]{3,18}$/;

@@ -24,1 +20,19 @@

exports.chinese = /[\u4e00-\u9fa5]/;
exports.contentType = /content-type/i;
exports.charset = /charset=('|")?([a-zA-Z-0-9-_]+)('|")?/i;
exports.utf8 = /utf-?8/i;
exports.matchCharset = function (str) {
var match = str.match(exports.charset);
return match ? match[2] : null;
}
exports.matchContentType = function (str) {
var match = str.match(exports.contentType);
return match ? match[0] : null;
}
{
"name": "reges",
"description": "A collection of regular expressions",
"version": "0.0.1",
"version": "0.0.2",
"author": "Shallker <imshallker@gmail.com>",

@@ -6,0 +6,0 @@ "main": "index.js",

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