Coder Social home page Coder Social logo

fleetadmiraljakob / nativewind Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nativewind/nativewind

0.0 0.0 0.0 289.56 MB

React Native utility-first universal design system - powered by Tailwind CSS

Home Page: https://nativewind.dev

License: MIT License

Shell 0.06% JavaScript 4.96% TypeScript 74.52% HTML 0.01% SCSS 1.62% MDX 18.83%

nativewind's Introduction

Tailwind CSS

NativeWind

npm version npm downloads Github Discord Twitter


About

Do you like using Tailwind CSS to style your apps? This helps you do that in React Native. NativeWind is not a component library, it's a styling library. If you're looking for component libraries that support NativeWind, see below.

NativeWind makes sure you're using the best style engine for any given platform (e.g. CSS StyleSheet or StyleSheet.create). It's goals are to to provide a consistent styling experience across all platforms, improving developer UX, component performance, and code maintainability.

NativeWind processes your styles during your application's build step and uses a minimal runtime to selectively apply reactive styles (eg changes to device orientation, light dark mode).

Installation

If you have an existing project, use these guides to configure NativeWind for your respective stack.

Alternatively, you can create a new pre-configured project via our Quickstart options, below.

Quickstart

You can get started with any of the following options:

Features

  • Works on all RN platforms, uses the best style system for each platform.
  • Uses the Tailwind CSS compiler
  • Styles are computed at build time
  • Small runtime keeps your components fast
  • jsxImportSourceTransform only wraps native components, making it lighter and such that the className prop is accessible inside your component
  • Respects all tailwind.config.js settings, including themes, custom values, and plugins
  • Support for
    • custom CSS properties, aka CSS Variables
    • dark mode, arbitrary classes, and media queries
    • animations and transitions
    • container queries
      • container-type and style-based container queries are not supported
    • pseudo classes - hover / focus / active on compatible components
    • rem units
    • theme functions and nested functions
    • React 18 Suspense API
    • Custom CSS
  • Styling based on parent state modifiers - automatically style children based upon parent pseudo classes
    • support for the group and group/<name> syntax
  • Children styles - create simple layouts based upon parent class
  • Fast and consistent style application via hot reload
    • includes changes made to tailwind.config.js

More details here

Distribution tags guide

  • Release: main branch (currently v2.0.11)
    • You should use this version
  • Experimental: next branch (currently v4.1)
    • You probably shouldn't use this version
    • Undergoing testing to move to a release version
  • Bleeding Edge: -alpha suffixed branches (no current alpha)
    • You should not use this version
    • Used internally for moving towards a next version

Contribution

See this guide

FAQ

Is NativeWind moving to Expo?

No. Expo is always exploring ways to handle styles better but NativeWind, as a project, will not be moving into the Expo organization.

What happened to v3?

Similar to Valve, we don't like the number 3. Nah, we had a V3 but it was a bad idea and needed to be reworked so we dropped it and moved on to v4.

What if I'm looking for a component library that uses NativeWind?

There are a number of different component libraries available that use NativeWind to achieve different results. You should pick the one that best suits your needs.

This multi-platform library focuses on achieving native feel for each individual platform using the familiar interface of Tailwind CSS.

This open source library offers universal shadcn/ui via React Native. Use this as a foundation to develop your own high-quality component library.

From the folks that brought you NativeBase, this library offers customizable cross-platform components designed to look & behave cleanly on every platform.

What are the breaking changes from v2 to v4?

All breaking changes are outlined here.

Documentation

Learn more on our website.

nativewind's People

Contributors

renovate[bot] avatar marklawlor avatar semantic-release-bot avatar renovate-bot avatar github-actions[bot] avatar danstepanov avatar jmeistrich avatar the-dijkstra avatar angeloanolin avatar sync avatar aviavinav avatar evanbacon avatar ferasaloudah avatar infinitexyy avatar johnf avatar jsellam avatar timedtext avatar bidah avatar viraj-10 avatar yjose avatar alisherks avatar amandeepmittal avatar andrefelipeschulle avatar amorriscode avatar arnaudambro avatar bingcoke avatar thefinnomenon avatar christianbauer1 avatar danscan avatar nandorojo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.