Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
@knorm/timestamps
Advanced tools
Timestamps plugin for @knorm/knorm.
This plugin adds the knex timestamp
fields to your models and also updates your query methods so that createdAt
and updatedAt
are set to the current time (i.e. new Date()
) for insert
calls and the updatedAt
field is set to the current time for any update
calls. It will also ensure that any update
calls do not overwrite the
createdAt
field.
npm install --save @knorm/knorm @knorm/timestamps
@knorm/timestamps has a peer dependency on @knorm/knorm
const knorm = require('@knorm/knorm');
const knormTimestamps = require('@knorm/timestamps');
const orm = knorm({
// knorm options
}).use(
knormTimestamps({
// knormTimestamps options
})
);
The name of the plugin, defaults to 'timestamps'
.
type: object, default:
{ name: 'createdAt', column: 'created_at' }
The createdAt
field can be configured with these options:
name
string, default: createdAt: the field namecolumn
string, default: created_at: the column nametype: object, default:
{ name: 'updatedAt', column: 'updated_at' }
The updatedAt
field can be configured with these options:
name
string, default: updatedAt: the field namecolumn
string, default: updated_at: the column nameFAQs
Timestamps plugin for @knorm/knorm
We found that @knorm/timestamps 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
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.