GithubHelp home page GithubHelp logo

goodwin64 / wix-style-react Goto Github PK

View Code? Open in Web Editor NEW

This project forked from justame/wix-style-react

0.0 1.0 0.0 18.59 MB

A collection of React components that conform to Wix Style.

Home Page: https://wix-style-react.now.sh

License: MIT License

JavaScript 92.29% CSS 6.78% Shell 0.08% TypeScript 0.45% HTML 0.39%

wix-style-react's Introduction

Wix Style React
A collection of React components that conform to Wix Style.

Dependencies DevDependencies

๐Ÿ“ฆ Install

npm install wix-style-react
yarn add wix-style-react

๐Ÿ”จ Setup

If ๐Ÿ‰yoshi build runner is used for your application then all required loaders are already defined. If you'd rather set up your project manually, take a look at our webpack guide.

Minimal Yoshi version to be used with wix-style-react:

Version 4 - ^4.1.0

Version 3 - ^3.31.2

Load Wix fonts from CDN:

<link
  rel="stylesheet"
  href="//static.parastorage.com/services/third-party/fonts/Helvetica/fontFace.css"
/>

Enable font smoothing with browser specific css properties:

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

Make sure that react and react-dom versions are not higher then:

  //package.json
 .
 .
 "react":"16.8.3",
 "react-dom":"16.8.3"
 .
 .
 

wix-style-react v6.x migration note:

If you're using wix-style-react 6.x and want to shift to 7.x version then read our migration guide.

Previous version documentation: https://wix-wix-style-react-v6.surge.sh/

๐Ÿš€ Usage

import { Button } from 'wix-style-react';

const App = () => (
  <Button>
    Click me!
  </Button>
);

๐Ÿ’ซ Testkits

All our components are provided with testkits that help our users test them.

A component testkit provides an interface to the component, enabling automated tests to access component functions without needing to know precise details of the technology being used.

//  Here is an example

// 1. import
import { inputTestkitFactory } from 'wix-style-react/dist/testkit';

// 2. initialize
const inputDriver = inputTestkitFactory({
  wrapper: document.body,
  dataHook: 'name-input',
});

// 3. interact
await inputDriver.enterText('hello world');

All methods are documented in our storybook components stories and some can be viewed through typescript interface.

Our testkits currently support four major testing frameworks: react-jsdom, protractor, puppeteer and selenium. Read our testing guidelines

โŒจ๏ธ Typescript

The library is javascript based but types are supported with d.ts files. Not all components have types defined, but it is ongoing process to make it so.

Additional type interfaces are added in a separate repo called: wsr-types in order not to break our existing users. Read more on the repo description: https://github.com/wix/wix-ui/tree/master/packages/wsr-types

๐Ÿค Contributing PRs Welcome

We welcome contributions to Wix-Style-React!

Read our contributing guide and help us build or improve our components.

๐Ÿ“ License

This project is offered under MIT License.

wix-style-react's People

Contributors

mykas avatar nitayneeman avatar argshook avatar nirhart avatar moshekerbel avatar egozie avatar talza1810 avatar simast avatar shlomitc avatar faradey27 avatar yardnsm avatar yanivefraim avatar 3lok avatar amiryonatan avatar mastertheblaster avatar interal avatar gilmeir avatar alonbt avatar ipanasenko avatar itaibenda avatar ronami avatar nitayrabi avatar jefoss avatar maxvektor avatar yavorsky avatar rghorbani avatar adavidof avatar netanelgilad avatar justenor avatar liorur avatar

Watchers

James Cloos 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.