
Dependent Controls is a library for making dependent drop-downs rapidly and simply. It’s written in pure ES6 JavaScript / TypeScript and doesn’t have any dependencies. The library helps SELECTs, radio buttons, and another customized HTML. Any CSS framework can be utilized for styling.

Common Options
- The library helps SELECT drop-downs, radio buttons, and any customized HTML…
- Any CSS framework or customized CSS can be utilized for styling.
- The library is written in fashionable ES6 + TypeScript; no dependencies are required.
- It has three information supply choices: one JSON file, a direct JavaScript object, or a customized operate that maximizes flexibility and permits to carry out AJAX requests.
- There may be native storage, session storage, and cookies help.
- Deep hyperlinks help.
- In depth documentation is included.
- It’s potential to have any variety of controls on the identical web page.
- The person finally defines all look & really feel of the web page; The library has minimal CSS kinds.

Examples
- Bootstrap CSS Framework DropDown Examples
- Bootstrap CSS Framework Radio Buttons & Switches
- Bootstrap CSS Framework Mixed Controls
- Tailwind CSS Framework DropDown Examples
- Tailwind CSS Framework Radio Buttons & Switches
- Tailwind CSS Framework Mixed Controls
- Bulma CSS Framework Examples
- Foundation CSS Framework Examples
- Pure CSS & AJAX Request
- AJAX example with five nesting levels
- SELECT with <optgroup>
- Drop-Down with Deep Link

Information Sources
The library helps three important information sources:
- Single JSON file. On this case, all information is positioned inside a single JSON file, which is loaded as soon as on web page load.
- Javascript object. This information supply is the best one. Simply create a JavaScript object and cross it to the library through the dataSource property.
- Customized operate. The customized operate permits to use any logic and, for instance, carry information from the server-side (through AJAX requests).

Storage & Deep Hyperlinks
The library helps storage to save lots of the present state and restore it after web page refresh or when the again button is pressed.
- Native storage – that is persistent storage that retains information even when the person closes the browser.
- Session storage – it will likely be cleared when the browser session is over, usually when the person closes the browser.
- Cookies – not like native and session storage, cookie values can be utilized on the server too. It’s additionally potential to outline cookies’ expiration date.
- Deep Hyperlinks – particular hyperlinks that ship customers instantly into the predefined drop-down choice state.

Callbacks & APIs
The library has varied callback operate which may be used to use the customized logic:
- onSubmit.
- onReset.
- onChangeStart.
- onChangeEnd.
- onDisableControl.
- onEnableControl.