1.0.1 • Published 1 year ago

odin-simple-dropdown v1.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

odin-simple-dropdown

Simple dropdown menu - click on button makes the menu appear :)

My first npm package with the-odin-project :D

usage

install: npm i odin-simple-dropdown

import in your project:

import dropdownMenu from "odin-simple-dropdown"

the default style is at ./node_modules/odin-simple-dropdown/style.css and is imported at index.js in the same location

syntax

dropdownMenu(btnTitle, ...elements)

example

dropdownMenu("Dropdown!", "Home", "About", "Contact")

it returns a dom node that you can append using append/appendChild

Alt text

license

ISC

1.0.1

1 year ago

1.0.0

1 year ago