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

vuecordion

v0.0.2

Published

Vue2 Accordion

Downloads

151

Readme

Vuecordion

A simple Vue 2 accordion component with Tailwind CSS utility classes installed. CSS classes can be replaced easily using provided props.

🛠 Install

npm install vuecordion or yarn add vuecordion

🔮 Usage

<template>
  <div class="w-full mx-auto md:max-w-md">
    
    <vuecordion 
    	:faq="faq"
        wrapper-class="bg-blue-500 text-white"
        icon-class="w-4 h-4 text-2xl transition duration-500 delay-200 transform" 
    />
    
  </div>
</template>

<script>
import Vuecordion from 'vuecordion'
import 'vuecordion/dist/vuecordion.css'
export default {
  components: {
    Vuecordion
  },
  data() {
    return {
      faq: [
        {q: 'What is the meaning of Lorem ipsum?', a: 'Literally it does not mean anything. It is a sequence of words without a sense of Latin derivation that make up a text also known as filler text, fictitious, blind or placeholder'},
        {q: 'Why is Lorem Ipsum Dolor used?', a: 'The Lorem Ipsum text is used to fill spaces designated to host texts that have not yet been published. They use programmers, graphic designers, typographers to get a real impression of the digital / advertising / editorial product they are working on.'},
        {q: 'What is the most used version?', a: 'Lorem ipsum dolor sit amet, consectetur adipisci elit, sed eiusmod tempor incidunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur. Quis aute iure reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint obcaecat cupiditat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.'},
        {q: 'What are the origins of Lorem Ipsum Dolor Sit?', a: 'Its origins date back to 45 BC. In fact, his words were randomly extracted from theDe finibus bonorum et malorum, a classic of Latin literature written by Cicero over 2000 years ago.'}
      ]
    }
  }
}
</script>

🧰 Props

| Props | Type | Default | Required | Description | |--------------------|:------:|-------------------------------------------------------------------------------------------------------------|:--------:|------------------------------------------| | faq | Array | | Yes | Array of questions and answers. | | wrapper-class | String | w-full space-y-2 | | Class binding for the main wrapper. | | question-wrapper | String | bg-gradient cursor-pointer flex flex-wrap font-semibold items-center px-2 py-1 py-2 rounded-sm text-white | | Class binding for the question wrapper. | | question-class | String | flex-1 | | Class binding for the question title. | | answer-class | String | p-2 text-sm bg-gray-100 transition duration-500 ease-in-out transform bg-white | | Class binding for the answer wrapper. | | icon-class | String | w-4 h-4 text-2xl transition duration-200 delay-200 transform | | Class binding for the plus sign wrapper. |

📝 Notes

  1. Tailwind CSS is recommended for this component. If are using other CSS framework, write your own custom CSS in the <style></style> area of the component.
  2. Currently only one question open at a time.

🙏 Thanks