Giter Site home page Giter Site logo

i-ad / universal-components-example Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kkemple/universal-components-example

0.0 0.0 0.0 333 KB

An example setup for universal components

Home Page: http://universal-components-example-storybook.surge.sh/

License: MIT License

JavaScript 100.00%

universal-components-example's Introduction

Universal Components Example

An example setup for building/testing/deploying universal components with React

Folder Structure

This project uses Lerna to make managing multiple NPM packages easier. Often times you will end up with other packages related to your universal components package and using Lerna makes managing the inter-dependencies easier.

  • packages: This directory holds the actual NPM packages you want to publish via Lerna (currently only the universal-components package.
  • examples: This directory holds a web and a native example app.

Available Scripts

lerna bootstrap

Hoists shared dependencies from any packges in packages directory. Also creates symlinks for inter-dependent packages in packages directory

lerna publish

Publishes new tags and package versions for any packages in packages directory that have changed since last publish

Running the Examples

Web

This app was created using create-react-app. And although CRA supports using react-native-web out of the box, we need to eject so that we can update Webpack config to also parse the universal components package (we must also do the same in prod Wepback config).

You can see the universal component being included here.

cd examples/web
yarn install
yarn start

Native

This app was created using create-react-native-app. There were no special setup steps required.

You can see the universal component being included here.

cd examples/native
yarn install
yarn start

universal-components-example's People

Contributors

kkemple 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.