Security News
Input Validation Vulnerabilities Dominate MITRE's 2024 CWE Top 25 List
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
@jaysalvat/smart-model
Advanced tools
Javascript object model.
Install npm package
npm install @jaysalvat/smart-model
import SmartModel from '@jaysalvat/smart-model'
<script src="https://unpkg.com/@jaysalvat/model@latest/build/smart-model.umd.min.js"></script>
Better documentation soon...
const Post = SmartModel.create('Post', {
title: {
required: true,
type: String,
},
body: {
required: true,
type: String,
},
date: {
type: Date,
default: new Date(),
transform: (value) => new Date(value),
format: (value) => new Date().toLocaleString()
}
})
const post = new Post({
title: 'my new post',
body: 'lorem ipsum...'
})
Dev mode
npm run dev
Build
npm run build
Lint
npm run lint
Fix lint errors
npm run lint:fix
Bump version and publish to NPM
npm run release
npm run release:patch
npm run release:minor
npm run release:major
FAQs
SmartModel is a fun experiment over Javascript Proxy. It tends to bring useful tools and best practices to data objects.
The npm package @jaysalvat/smart-model receives a total of 3 weekly downloads. As such, @jaysalvat/smart-model popularity was classified as not popular.
We found that @jaysalvat/smart-model 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
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.