GithubHelp home page GithubHelp logo

klaufel / pattern-library-skeleton Goto Github PK

View Code? Open in Web Editor NEW
77.0 4.0 29.0 3.52 MB

#zapatillasFromMarsπŸ‘ŸπŸš€ A awesome design system for your products and experiences!

Home Page: https://pattern-library-skeleton.netlify.com/

JavaScript 84.06% HTML 0.69% Swift 6.79% Objective-C 3.53% CSS 4.93%

pattern-library-skeleton's Introduction

#zapatillasFromMarsπŸ‘ŸπŸš€

πŸ‘‹ Welcome to pattern library skeleton

An awesome design system for your products and experiences!

Netlify Status

Overview β€’ Getting Started β€’ Architecture β€’ Guidelines β€’ Testing

Design tokens figma file

πŸ”₯ Overview

We use the best tools to improve our workflow, allowing us to create an awesome library of components!

πŸš€ Getting Started

To get started you need to meet the prerequisites, and then follow the installation instructions.

Figma design tokens example

Figma file: https://www.figma.com/file/IGr2xoqcZX91CU7CDr4ZsI

For more info on configuring your design tokens file, visit "How to configure design tokens with Figma API"

Installing

You can clone our Git repository:

$ git clone [email protected]:klaufel/pattern-library-skeleton.git

Wiring up your development environment

Hooking it up is as easy as running:

$ npm run install

This command will install all the required dependencies. Please note that npm install is only required on your first start, or in case of updated dependencies.

Initializing Storybook

$ npm run storybook

Generate design tokens as variables

$ npm run tokens

πŸ“ Architecture

Based on the Atomic Design principles, a methodology for creating design systems, there are five distinct levels of components:

  • Atomic Design component structure:
    • Atoms
    • Molecules
    • Organism
    • Templates
    • Pages

When we use a UI library, the highest abstraction of components that we expose would be an organism. The rest of the template and page components are built within the application that imports the library.

Source project structure:
└── src
    β”œβ”€β”€ components
    β”‚	β”œβ”€β”€ atoms
    β”‚	β”œβ”€β”€ molecules
    β”‚	β”œβ”€β”€ organism
    β”‚	└── pages *
    β”œβ”€β”€ docs
    β”œβ”€β”€ figma-tokens
    β”œβ”€β”€ styles
    └── index.js (entry point)
  • src: The place where we put our application source code - components Add your components here! This folder is divided from Atomic Design principles.
  • docs Our documentation as stories for the design system.
  • figma-tokens Directory containing functions to generate figma design tokens with API.
  • styles Directory to add global styles and theme to build components.
  • index.js Entry point, import all components and export to generate package to use in project as a dependency.

Example of component structure
└── MyComponent
    β”œβ”€β”€ __stories__
    β”‚   └── MyComponent.stories.{js|mdx}
    β”œβ”€β”€ __tests__
    β”‚	β”œβ”€β”€ __snapshots__
    β”‚	β”‚   └── MyComponent.test.js.snap
    β”‚   └── MyComponent.test.js
    β”œβ”€β”€ MyComponent.styles.js
    └── index.js
  • mycomponent: Directory containing our component.
    • __stories__: Directory containing the stories for Storybook.
      • MyComponent.stories.js: File containing the component stories.
    • __tests__: Directory containing the tests for Jest.
      • __snapshots__: Directory containing the autogenerated Jest Snapshots.
        • MyComponent.test.js.snap: Autogenerated Snapshot file.
      • MyComponent.test.js: File containing the component tests.
    • MyComponent.styles.js: File containing the component styles (styled-components / CSS-in-JS).
    • index.js: File containing the React component, HTML or other imports from ui-library.

πŸ’… Guidelines

Linting

$ npm run lint Find problems in your code (js)

Formatter

$ npm run prettier:check Find format problems in your code.

$ npm run prettier:write Fix format problems in your code.

πŸ™ Testing the application

Jest, a delightful javascript testing framework and Testing Library build on top of DOM testing library by adding APIs for working with React components.

Running your tests

$ npm run test Will perform your unit testing.

$ npm run test:update Will perform your unit testing and update snapshots.

$ npm run test:watch Will perform your unit testing and watchers tests.

$ npm run test:coverage Will perform your unit testing and show coverage.

$ npm run test:coverage-web Will perform your unit testing, show coverage, and open the report in your default browser.

pattern-library-skeleton's People

Contributors

aarongarciah avatar breadadams avatar klaufel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

pattern-library-skeleton's Issues

'bin' is not recognized as an internal or external command

Hola, me ha salido este error cuando intento ejecutar los tokens. He visto tu video en el canal de zapatillas from mars y he quedado fascinada con los designs tokens. Sin embargo me quedan muchas dudas, cuando corro el storybook no tengo acceso ni veo el editor que sale en tu video a la derecha de la pantalla, no lo pillo, estoy comenzando con esto porque en realidad soy designer no developer. Espero que puedas ayudarme, se que el video es viejo pero no he encontrado informacion tan completa como esto en internet. Saludos!

[email protected] tokens:api
bin/figma-tokens

'bin' is not recognized as an internal or external command,
operable program or batch file.

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.