
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.
beautinator
Advanced tools
beautinator
A quick and dirty javascript pretty printer for javascript objects that runs in the browser. Works for objects that contain functions.
var result = beautinator({ "font-size": "26px","font-family": "'Open Sans', sans-serif",color: "white", overflow: "hidden",padding: "4px 4px 4px 8px",Text: { display: "block", width: "100%","text-align": "center", "padding-left": "2px","word-break": "break-word"}})
console.log(result)
Result:
{ "font-size": "26px",
"font-family": "'Open Sans', sans-serif",
color: "white", overflow: "hidden",
padding: "4px 4px 4px 8px",
Text: { display: "block", width: "100%",
"text-align": "center", "padding-left": "2px",
"word-break": "break-word"
}
}
I wanted a module that can print beautify javascript objects and runs in the browser. But all the modules I could find are either heavy-weight server-only libraries like prettier and js-prettify, or libraries that don't return valid javascript like fmt-obj and pretty-format. I did find https://github.com/xpl/string.ify but it cause me trouble since it was written in ES6, which my tools don't support yet.
npm install beautinator
Accessing beautinator:
// node.js
var beautinator = require('beautinator')
// amd
require.config({paths: {beautinator: '../dist/beautinator.umd.js'}})
require(['beautinator'], function(beautinator) { /* your code */ })
// global variable
<script src="beautinator.umd.js"></script>
beautinator; // beautinator.umd.js can define beautinator globally if you really
// want to shun module-based design
Using keysight:
var result = beautinator(jsObject)
result
will contain the object stringified.Anything helps:
How to submit pull requests:
npm install
at its roottargetWidth
Released under the MIT license: http://opensource.org/licenses/MIT
FAQs
A quick and dirty pretty printer for javascript objects
The npm package beautinator receives a total of 0 weekly downloads. As such, beautinator popularity was classified as not popular.
We found that beautinator 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.
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.