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 🙏

© 2026 – Pkg Stats / Ryan Hefner

marquee6k

v1.3.4

Published

Super smooth, lightweight vanilla JavaScript marquee library. No dependencies. High performance.

Readme

marquee6k

marquee6k is a super smooth, lightweight vanilla JavaScript marquee library.
No dependencies. High performance.
Marquees forever ✨

Initialize

marquee6k.init()

Features

  • ~3kb minified with no dependencies
  • Turn any element into a smooth-as-butter marquee
  • Style marquees as usual with CSS
  • Set speed and direction
  • Have a ton without any slowdown
  • Responsive
  • Access Marquee instances globally

Usage

  1. Include marquee6k in your html file.

    It is the best to place it before the closing </body> tag. This ensures that all HTML elements are loaded before the script tries to animate them.

    local:
    Download or install via npm install marquee6k.

    via jsDelivr:

    <!-- Latest version -->
    <script src="https://cdn.jsdelivr.net/gh/SPACESODA/marquee6k@latest/marquee6k.min.js"></script>

    via npm:

        const marquee6k = require('marquee6k');
        // or
        import marquee6k from 'marquee6k';
        <script src="marquee6k.js"></script>
  2. Create an element with a .marquee6k class.
    You can pass different options such as speed, orientation and direction (optional). See below for options.

        <div class="marquee6k" 
            data-speed="0.25" → play around here
            data-reverse="bool" → default: R to L / T to B
            data-pausable="bool" → Pause marquee on hover>
            <!--you can even have inline images, or any kind of html -->
            <h1>Some marquee content</h1>
        </div>
  3. Fill it up with text or images etc. (still finding out what you can do with it)

  4. In your js file or <script> just call marquee6k.init() and you're all set!

  5. To set spacing and other wonderful things, please use css (each repeated segment gets a ${selector}__copy class – default is marquee6k__copy; the diagonal-marquee wrapper below is just an example, not required)

        /* Example: Optional wrapper to rotate/transform the whole marquee */
        .diagonal-marquee {
            transform: rotate(45deg);
        }
    
        /* Each repeated segment uses `${selector}__copy` (default: .marquee6k__copy) */
        .marquee6k__copy {
            padding-right: 30px;
            box-sizing: border-box;
        }

Good stuff

Refresh

You can refresh (if width of the inner content changes dynamically) by:

    // Refresh all instances
    marquee6k.refreshAll();

    // or, since all marquees are available globally, target a specific instance
    marquee6k.refresh(index); // index of marquee

Pause

You can stop the animation by:

    // Refresh all instances
    marquee6k.pauseAll();

    // or target a specific instance
    marquee6k.pause(index); // index of marquee

Play

You can start the animation after being paused by:

    // Refresh all instances
    marquee6k.playAll();

    // or target a specific instance
    marquee6k.play(index); // index of marquee

Toggle

You can toggle the animation by:

    // Refresh all instances
    marquee6k.toggleAll();

    // or target a specific instance
    marquee6k.toggle(index); // index of marquee

Important

If you are using images or custom fonts, initialise marquee6k AFTER they have been loaded!

Options

You can set additional configuration options.

    marquee6k.init({
        selector: '.selector-name', // define a custom classname
    });

Marquee also adds a is-init selector. You can use this to add and toggle entrance transitions, for example.

Build

The source of truth is src/marquee6k.ts. Build outputs are generated so the same code works both via a plain <script> tag (UMD) and via import (ESM), without maintaining two separate implementations.

npm install
npm run build

Questions

Q: But it's slow, I have 150+ of them on the same page

A: If you've got literally hundreds of them on one page, you've got a marquee addiction problem.

Q: Does it work on mobile?

A: Yes it does and it works quite well! If you're going to be rotating things and all that fancy stuff, just make sure to style it with CSS.

Q: Can i make a marquee that's position fixed?

A: Absolutely. You just have to wrap the marquee element inside another container which gets the position: fixed.

Q: The callback does not work?

A: You have to pass in only the name of the function (must be defined in global scope). Still currently a very basic implementation. Suggestions welcome!

Credits

This project is a fork of the popular (but long unmaintained) Marquee3000. If 3000 is a millennium, I guess 6000 is forever. Don't ask me why.

The marquee6k codebase has been fully modernized with TypeScript, squashed lingering bugs, and polished it up for the modern web. Same butter-smooth performance, just future-proofed.

License

This project is licensed under the MIT License.