Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
hof-component-date
Advanced tools
A hof middleware for rendering and processing 3 part date fields
#HOF-Component-Date
A component for handling the rendering and processing of 3-input date fields used in HOF Applications.
##Usage
In your fields config:
const dateComponent = require('hof-component-date');
module.exports = {
'date-field': dateComponent('date-field', {
validate: ['required', 'before']
})
}
The above example will create a new date component with the key 'date-field'
and will apply the validators required
and before
(before today).
##Configuration
The following optional configuration options are supported:
validate {String|Array}
- validators to use on the processed date fieldtemplate
- an absolute path to an alternate template.dayOptional {Boolean}
- day defaults to 01
if omitted. Defaults to false
monthOptional {Boolean}
- month defaults to 01
if omitted. If true then also forces dayOptional
to be true. Defaults to false
##Labels
The three intermedate fields have fallback labels of Day, Month and Year, however custom labels can be used by including the translation at the following path:
fields.json
{
"field-name": {
"parts": {
"day": {
"label": "Custom Day Label"
},
"month": {
"label": "Custom Month Label"
},
"year": {
"label": "Custom Year Label"
}
}
}
}
FAQs
A hof middleware for rendering and processing 3 part date fields
The npm package hof-component-date receives a total of 0 weekly downloads. As such, hof-component-date popularity was classified as not popular.
We found that hof-component-date demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 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
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.