
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
pretty-camel
Advanced tools
Node module to format to and from camel case.
var prettyCamel = require("pretty-camel");
prettyCamel(input, {
"case": "title" (default) | "sentence" | "lower"
});
prettyCamel.toWords(input, {
"case": "title" (default) | "sentence" | "lower"
});
prettyCamel.toWords()
is aliased to prettyCamel()
so it can be used either way.
Here are a few examples of prettification:
The following rules are applied to input strings:
Options are passed in an object as the second parameter. Currently the only option available is casing.
var prettyCamel = require("pretty-camel");
prettyCamel.toCamelCase(input, {
"case": "lower" (default) | "upper"
});
Here are a few examples:
Options are passed in an object as the second parameter. Currently the only option available is casing.
var prettyCamel = require("pretty-camel");
var input = "hospitalCPTCode";
var output = prettyCamel(input);
console.log(output);
The outputs is Hospital CPT Code
var prettyCamel = require("pretty-camel");
var input = "hospitalCPTCode";
var options = {
"case": "sentence"
};
var output = prettyCamel.toWords(input, options);
console.log(output);
The outputs is Hospital CPT code
var prettyCamel = require("pretty-camel");
var input = "hospitalCPTCode";
var options = {
"case": "lower"
};
var output = prettyCamel(input, options);
console.log(output);
The outputs is hospital CPT code
var prettyCamel = require("pretty-camel");
var input = "hospital_CPT_Code";
var options = {
"case": "upper"
};
var output = prettyCamel.toUpperCase(input, options);
console.log(output);
The outputs is HospitalCPTCode
npm install pretty-camel
If you're using Express and want access to prettyCamel() in your views, add the following piece of middleware to your server:
var prettyCamel = require("pretty-camel");
var express = require("express");
var app = express.createServer();
app.use(prettyCamel.middleware);
Version 0.0.7 was compatible with Express 2.x and 0.0.8 and above are compatible with Express 3.x.
FAQs
Node module to prettify camel cased strings.
The npm package pretty-camel receives a total of 216 weekly downloads. As such, pretty-camel popularity was classified as not popular.
We found that pretty-camel demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.