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

twify

v0.5.0

Published

A Tool to Setup TailwindCSS in your Project with a Single Command

Downloads

19

Readme

Twify

:rocket: New Project

Scaffold a new project of your choice of framework, with tailwindcss

npx twify@latest create vite <my-app-directory>

# Or with preferred package Manager
# Yarn
npx twify@latest yarn create vite <my-app-directory>
# PNPM
npx twify@latest pnpm create vite <my-app-directory>

Above the project that is specified is vite. You can choose any of the following.

Project Usage:

Below commands will install the @latest versions of the respective frameworks.

| Framework | Command | | ---------------- | ------------------------------------------ | | Next 13 | npx twify@latest create next <my-app> | | Remix | npx twify@latest create remix <my-app> | | Nuxt 2 | npx twify@latest create nuxt <my-app> | | Nuxt 3 | npx twify@latest create nuxt3 <my-app> | | Svelte Kit | npx twify@latest create svelte <my-app> | | Laravel Vite | npx twify@latest create laravel <my-app> | | Vite | npx twify@latest create vite <my-app> | | Solid Start | npx twify@latest create solid <my-app> | | Angular | npx twify@latest create angular <my-app> | | Create React App | npx twify@latest create react <my-app> |

You can pass all the framework specific flags as well like the following,

npx twify@latest pnpm create vite my-vite-app --template vue-ts

Above will create a new project with the vite vue typescript project with the pnpm package manager and it will be configured with Tailwind CSS.

:gift: Existing Project

You can also configure existing project with tailwindcss.

npx twify@latest init

Command Options

Other than --help you can also do more.

Keep Existing CSS

By default, twify will replace your existing CSS and only keep Tailwind. But if you want to keep the existing CSS you can use the -k, --keep flag.

npx twify init -k
# OR
npx twify init --keep

Force Package Manager for Installation

By default, twify will try to guess the Package Manager for installing dependencies in your project but if you want to force your standard or you don't want to take any chances you can use the -i, --installer option.

npx twify init -i yarn # Options: npm, yarn, pnpm
# OR
npx twify init --installer yarn

Configure Tailwind Prettier

Optionally if you want to install the Tailwind Prettier Plugin also, you can opt for -p, --pretty flag. Because this plugin doesn't play well with other prettier plugins it is kept under the flag not a default.

npx twify init -p
# OR
npx twify init --pretty

:star: Supported Projects

Below are the list of Supported Projects,

| Framework | Javascript | Typescript | | ---------------- | ------------------ | ------------------ | | Next 13 | :white_check_mark: | :white_check_mark: | | Remix | :white_check_mark: | :white_check_mark: | | Nuxt 2 | :white_check_mark: | :white_check_mark: | | Nuxt 3 | :white_check_mark: | :white_check_mark: | | Svelte Kit | :white_check_mark: | :white_check_mark: | | Laravel Vite | :white_check_mark: | :white_check_mark: | | Vite | :white_check_mark: | :white_check_mark: | | Angular | :white_check_mark: | :white_check_mark: | | Create React App | :white_check_mark: | :white_check_mark: | | Solid JS | :white_check_mark: | :white_check_mark: | | Astro | :o: WIP | :o: WIP | | Qwik | :o: WIP | :o: WIP |

:microscope: Testing

After Cloning the repository, install all npm dependencies by running: npm install.

Then Run Tests:

$ npm run test
$ npm run coverage

:date: Change log

Please see release history for more information on what has changed recently.

:heart: Contributing

Please feel free to contribute ideas and PRs are most welcome.

:crown: Credits

:policeman: License

The MIT License (MIT). Please see License File for more information.