npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@dao-vue/dropdown

v0.0.2

Published

A dropdown component for VueJS by @Dao-Vue.

Downloads

1

Readme

How To

Install in Vue projects?

To install as a plugin/package/library/extension and whatever, generally the "DaoDropdown",

  1. You need to open the directory of your project using CMD/Terminal.
  2. Then, write this script: npm install @dao-vue/dropdown
  3. And wait till the installation ends. So then you can begin using.

Use it by including a CDN.

Now, I show you many ways of using CDN and JS files. Before using any CDN link, let's get acquainted with them. So, you should know if you don't know what is modularity. If you want to use more effective one choose UMD version.

CJS - CJS is short for CommonJS. Some of you know it from Node. Because it uses CJS module format. CJS imports module synchronously.You can import from a library node_modules or local dir. Either by const myLocalModule = require('./some/local/file.js') or var React = require('react'); works. When CJS imports, it will give you a copy of the imported object. CJS will not work in the browser. It will have to be transpiled and bundled.

ESM - ESM stands for ES Modules. It is Javascript's proposal to implement a standard module system. Works in many modern browsers It has the best of both worlds: CJS-like simple syntax and AMD's async Tree-shakeable, due to ES6's static module structure ESM allows bundlers like Rollup to remove unnecessary code, allowing sites to ship less codes to get faster load. Even can be called in HTML and this may not work 100% in all browsers yet.

AMD - AMD stands for Asynchronous Module Definition. AMD imports modules asynchronously (hence the name). AMD is made for frontend (when it was proposed) (while CJS backend). AMD syntax is less intuitive than CJS. I think of AMD as the exact opposite sibling of CJS.

UMD - UMD stands for Universal Module Definition. Works on front and back end (hence the name universal). Unlike CJS or AMD, UMD is more like a pattern to configure several module systems. Check here for more patterns. UMD is usually used as a fallback module when using bundler like Rollup/ Webpack

Summary

  • ESM is the best module format thanks to its simple syntax, async nature, and tree-shakeability.
  • UMD works everywhere and usually used as a fallback in case ESM does not work
  • CJS is synchronous and good for back end.
  • AMD is asynchronous and good for front end.

Now, I show you where the JS files are.

So you can get their CSS files by replacing .js in the filename end into .css

  1. ESM.JS modularity
    • JSDELIVR - https://cdn.jsdelivr.net/npm/@dao-vue/[email protected]/dist/dao-dropdown.esm.js
  2. ESM.JS& MINIFIED VERSION
    • coming soon
  3. UMD.JS modularity
    • JSDELIVR - https://cdn.jsdelivr.net/npm/@dao-vue/[email protected]/dist/dao-dropdown.umd.js
  4. UMD & MINIFIED VERSION
    • coming soon
  5. CJS.JS VERSION
    • coming soon
  6. CJS.JS modularity with minification
    • JSDELIVER - https://cdn.jsdelivr.net/npm/@dao-vue/[email protected]/dist/dao-dropdown.min.js
  7. AMD.JS VERSION
    • coming soon
  8. AMD & MINIFIED VERSION
    • coming soon

Have a happy coding :smile:!