Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
type-analyzer
Advanced tools
Infer types from CSV columns.
This package provides a single interface for generating the datatype for a given row-column formatted dataset. We support the following datatypes:
npm install type-analyzer
Usage is super simple, simply call computeColMeta on your data like so
var Analyzer = require('type-analyzer').Analyzer;
var colMeta = Analyzer.computeColMeta(data);
But imagine you want to ensure that a column full of ids represented as numbers is identified as a column of strings, type-analyzer's got you. Simply pass an array of rules:
var Analyzer = require('type-analyzer').Analyzer;
var colMeta = Analyzer.computeColMeta(data, [{name: 'id', dataType: 'STRING'}]);
// or
var colMeta = Analyzer.computeColMeta(data, [{regex: /id/, dataType: 'STRING'}]);
Note: Analyzer prefers rules using name over regex since better performance.
And it will short cut around the usual analysis system and give you back the column formatted as you'd expect.
Breaking changes with v1.0.0: Regex has moved into src, but can more easily be accessed from the module.exports from the root. As part of a larger clean up many extraneous util files were removed.
[0.1.1] Dec 18 2018 (e665758)
5376d1c add unix timestamp tests c0734c9 added unix time format a796a7b update readme, make year regex recognize 2 digit year 3d0fa1a from git@github.com:uber-web/type-analyzer.git
FAQs
Infer types from columns in JSON
The npm package type-analyzer receives a total of 1,747 weekly downloads. As such, type-analyzer popularity was classified as popular.
We found that type-analyzer demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.