
Product
Introducing Webhook Events for Pull Request Scans
Add real-time Socket webhook events to your workflows to automatically receive pull request scan results and security alerts in real time.
dependent-select-boxes
Advanced tools
Allows a child select box to change its options dependent on its parent select box
dependent-select-boxes
allows a child select box to change its options dependent on its parent select box.
You can pass in options as a third parameter. The currently supported options are:
childOptionIsDependentOnParentOption(childOption, parentOption)
:
Function that determines if the childOption
should be displayed if
parentOption
is selected. Default: true
if the value of the parent
option is a prefix of the value of the child option, else false
.resetParentOptionOnEmptyChildOption
:
Resets the parent option to an empty value if the child option changes
to an empty option. Default true
.new DependentSelectBoxes(document.getElementById('parent'), document.getElementById('child'), {
childOptionIsDependentOnParentOption(childOption, parentOption) {
...
},
resetParentOptionOnEmptyChildOption: false,
});
You can configure the default options by setting them via:
import { setDefaultOptions } from 'dependent-select-boxes';
setDefaultOptions({
...
});
// npm install dependent-select-boxes --save
import DependentSelectBoxes from 'dependent-select-boxes';
const dependentSelectBoxes = new DependentSelectBoxes(parent, child, options);
If you would like to submit a pull request
with any changes you make, please feel free!
Simply run npm test
to test and npm start
to compile before submitting pull requests.
Please use the GitHub issue tracker to raise any problems or feature requests.
FAQs
Allows a child select box to change its options dependent on its parent select box
We found that dependent-select-boxes 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.
Product
Add real-time Socket webhook events to your workflows to automatically receive pull request scan results and security alerts in real time.
Research
The Socket Threat Research Team uncovered malicious NuGet packages typosquatting the popular Nethereum project to steal wallet keys.
Product
A single platform for static analysis, secrets detection, container scanning, and CVE checks—built on trusted open source tools, ready to run out of the box.