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

mining-utils

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mining-utils - npm Package Compare versions

Comparing version 0.4.8 to 0.4.9

2

index.js

@@ -1,1 +0,1 @@

"use strict";function __export(e){for(var r in e)exports.hasOwnProperty(r)||(exports[r]=e[r])}Object.defineProperty(exports,"__esModule",{value:!0}),__export(require("./src/util/removeAccent")),__export(require("./src/util/removePunctuation")),Object.defineProperty(exports,"__esModule",{value:!0});const fs_1=require("fs"),path_1=require("path"),files=[path_1.join("index.js")];for(const e of files){const r=fs_1.readFileSync(e).toString().replace(new RegExp(/\.\/util/,"g"),"./src/util");fs_1.writeFileSync(e,r)}Object.defineProperty(exports,"__esModule",{value:!0});const accents="ÀÁÂÃÄÅàáâãäåÒÓÔÕÕÖŐòóôõöőÈÉÊËèéêëðÇĈçĉÐǵĝĜǴĥḧḦĤÌÍÎÏìíîïĵĴḱḰĺĹḿḾńǹŃǸÙÚÛÜŰùúûüűÑñṕṔŕŔśŝŜŚŠšẗǘǜṽṼẃẁŵẅẄẂẀŴẍẌýỳŷỹÿýỸÝỲŶŸžźẑẐŹŽ",noAccents="AAAAAAaaaaaaOOOOOOOooooooEEEEeeeeeCCccDggGGhhHHIIIIiiiijJkKlLmMnnNNUUUUUuuuuuNnpPrRssSSSstuuvVwwwwWWWWxXyyyyyyYYYYYzzzZZZ",removeAccents=e=>{try{const r={};return accents.split("").forEach((e,t)=>r[e]=noAccents[t]),e.replace(/[^A-Za-z0-9]/g,e=>r[e]||e)}catch(e){console.log('This function can handle just strings.\nExample: removeAccents("All your string here.")',e)}};exports.removeAccents=removeAccents;const removeAccentsArray=e=>{try{const r={},t=[];accents.split("").forEach((e,t)=>r[e]=noAccents[t]);for(const n in e)t.push(e[n].replace(/[^A-Za-z0-9]/g,e=>r[e]||e));return t}catch(e){console.log('This function can handle just string arrays.\nExample: removeAcentsArray(["First", "Second", "Third"])',e)}};exports.removeAccentsArray=removeAccentsArray,Object.defineProperty(exports,"__esModule",{value:!0});const punctuations="^a-zA-Z\\d\\sÀÁÂÃÄÅàáâãäåÒÓÔÕÕÖŐòóôõöőÈÉÊËèéêëðÇĈçĉÐǵĝĜǴĥḧḦĤÌÍÎÏìíîïĵĴḱḰĺĹḿḾńǹŃǸÙÚÛÜŰùúûüűÑñṕṔŕŔśŝŜŚŠšẗǘǜṽṼẃẁŵẅẄẂẀŴẍẌýỳŷỹÿýỸÝỲŶŸžźẑẐŹŽ",removePunctuation=e=>{const r=new RegExp(`[${punctuations}]`,"g");return(e=e.replace(r,"")).replace(/\s\s+/g," ")};exports.removePunctuation=removePunctuation;const removeBlankSpace=e=>e.replace(/\s\s+/g," ");exports.removeBlankSpace=removeBlankSpace;const removePunctuationArray=e=>{const r=new RegExp(`[${punctuations}]`,"g"),t=[];for(const n in e)t.push(e[n].replace(r,"").replace(/\s\s+/g," "));return t};exports.removePunctuationArray=removePunctuationArray;const removeBlankSpaceArray=e=>{const r=[];for(const t in e)r.push(e[t].replace(/\s\s+/g," "));return r};exports.removeBlankSpaceArray=removeBlankSpaceArray;
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const fs_1=require("fs"),path_1=require("path"),files=[path_1.join("index.js")];for(const e of files){const r=fs_1.readFileSync(e).toString().replace(new RegExp(/\.\/util/,"g"),"./src/util");fs_1.writeFileSync(e,r)}Object.defineProperty(exports,"__esModule",{value:!0});const accents="ÀÁÂÃÄÅàáâãäåÒÓÔÕÕÖŐòóôõöőÈÉÊËèéêëðÇĈçĉÐǵĝĜǴĥḧḦĤÌÍÎÏìíîïĵĴḱḰĺĹḿḾńǹŃǸÙÚÛÜŰùúûüűÑñṕṔŕŔśŝŜŚŠšẗǘǜṽṼẃẁŵẅẄẂẀŴẍẌýỳŷỹÿýỸÝỲŶŸžźẑẐŹŽ",noAccents="AAAAAAaaaaaaOOOOOOOooooooEEEEeeeeeCCccDggGGhhHHIIIIiiiijJkKlLmMnnNNUUUUUuuuuuNnpPrRssSSSstuuvVwwwwWWWWxXyyyyyyYYYYYzzzZZZ",removeAccents=e=>{try{const r={};return accents.split("").forEach((e,n)=>r[e]=noAccents[n]),e.replace(/[^A-Za-z0-9]/g,e=>r[e]||e)}catch(e){console.log('This function can handle just strings.\nExample: removeAccents("All your string here.")',e)}};exports.removeAccents=removeAccents;const removeAccentsArray=e=>{try{const r={},n=[];accents.split("").forEach((e,n)=>r[e]=noAccents[n]);for(const t in e)n.push(e[t].replace(/[^A-Za-z0-9]/g,e=>r[e]||e));return n}catch(e){console.log('This function can handle just string arrays.\nExample: removeAcentsArray(["First", "Second", "Third"])',e)}};exports.removeAccentsArray=removeAccentsArray,Object.defineProperty(exports,"__esModule",{value:!0});const punctuations="^a-zA-Z\\d\\sÀÁÂÃÄÅàáâãäåÒÓÔÕÕÖŐòóôõöőÈÉÊËèéêëðÇĈçĉÐǵĝĜǴĥḧḦĤÌÍÎÏìíîïĵĴḱḰĺĹḿḾńǹŃǸÙÚÛÜŰùúûüűÑñṕṔŕŔśŝŜŚŠšẗǘǜṽṼẃẁŵẅẄẂẀŴẍẌýỳŷỹÿýỸÝỲŶŸžźẑẐŹŽ",removePunctuation=e=>{const r=new RegExp(`[${punctuations}]`,"g");return(e=e.replace(r,"")).replace(/\s\s+/g," ")};exports.removePunctuation=removePunctuation;const removeBlankSpace=e=>e.replace(/\s\s+/g," ");exports.removeBlankSpace=removeBlankSpace;const removePunctuationArray=e=>{const r=new RegExp(`[${punctuations}]`,"g"),n=[];for(const t in e)n.push(e[t].replace(r,"").replace(/\s\s+/g," "));return n};exports.removePunctuationArray=removePunctuationArray;const removeBlankSpaceArray=e=>{const r=[];for(const n in e)r.push(e[n].replace(/\s\s+/g," "));return r};exports.removeBlankSpaceArray=removeBlankSpaceArray;
{
"name": "mining-utils",
"version": "0.4.8",
"version": "0.4.9",
"description": "",

@@ -12,3 +12,3 @@ "author": "Oracy Rezende Martos <oramartos_21@hotmail.com> (https://github.com/Oracy)",

"test": "mocha -r ts-node/register test/**/*.ts",
"build": "npm run build:remove-previous && npm run build:transpile && npm run build:minify && npm run build:clean && npm run build:after",
"build": "npm run build:remove-previous && npm run build:transpile && npm run build:minify && npm run build:clean",
"build:remove-previous": "rm -f ./index.js ./index.d.ts",

@@ -15,0 +15,0 @@ "build:minify": "gulp minify",

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