1.0.5 ā€¢ Published 6 years ago

vraw v1.0.5

Weekly downloads
8
License
MIT
Repository
github
Last release
6 years ago

vraw

šŸŒ± Vraw is a implementation of react stateless components that can be used as a npm package in your projects.

Vraw Logomark with text "vraw" under the symbol

Usage

using npm:

$ npm install vraw --save

in code:

import React, { Component } from "react";
// importing Clock component
import { Clock } from "vraw";

class App extends Component {
  render() {
    return (
      // using Clock component
      <Clock msg="It works!" date={new Date()} />
    );
  }
}

export default App;

Motivation

Components are cool! We should use them everywhere. So, you expent time developing a lot of components and now you want to reuse them in another awesome project & all your projects need your components updated when a new feature is released (and you also need typechecking, tests, hot module replacement & all the good stuff).

Directory Structure

.
ā”œā”€ā”€ src
|   ā””ā”€ā”€ components
|       ā””ā”€ā”€ MyComponent                 # Your component
|           ā”œā”€ā”€ MyComponent.story.tsx   # Storybook of your component
|           ā”œā”€ā”€ MyComponent.test.tsx    # Jest + Enzyme tests
|           ā”œā”€ā”€ MyComponent.tsx         # Its JSX + Typescript file
|           ā”œā”€ā”€ MyComponent.types.ts    # Types for props
|           ā””ā”€ā”€ index.ts                # Export Component
|       ā””ā”€ā”€ MyComponentX                # Another component X
|       ā””ā”€ā”€ MyComponentY                # Another component Y
|       ā””ā”€ā”€ MyComponentZ                # Another component Z
|       ā””ā”€ā”€ stories.tsx                 # Storybook config file
ā”œā”€ā”€ dist
|    ā””ā”€ā”€ index.js                       # Exporting all Componentss

Features

  • React
  • Typescript
  • Storybook
  • Jest
  • Enzyme
  • Webpack
  • Prettier
  • Commitizen

Workflow

See presentation

Repository Workflow

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago