Giter Site home page Giter Site logo

manniru / simple-static-react-aframe Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jon-biz/simple-static-react-aframe

0.0 2.0 0.0 76 KB

Minimal boilerplate and configuration for the development of static VR sites using aframe, react & es6

License: MIT License

HTML 4.44% JavaScript 94.39% CSS 1.17%

simple-static-react-aframe's Introduction

#Simple Static React-Aframe

This repo is minimal boilerplate for VR sites written in React and Aframe.

It is intended for to get you up and developing with a minimum of fuss and configuration for a static, single page React & Aframe site. This repo gives you:

  • ES6/React (with sourcemaps)
  • Aframe & React-Aframe
  • CSS modules
  • watchfile'd development builds

And that's it.

You can see the initial output here:

http://elbizri.com/carpet/

The carpet and cube are created by the root component, so you can get quickly remove them. Sky, Earth, Camera and Cursor are all their own external components.

About React-Aframe:

Kevin Ngo's straight-forward wrapper React-Aframe ( https://github.com/ngokevin/aframe-react ) provides a React Components for Aframe's <a-scene>, <a-entity> and <a-animation> components. It should be pretty obvious from the code here how React Component props map to Aframe components.

(You can still call the aframe's components directly if you want, but you'll need to stringify de-stringify the component arguments yourself - obviously this is not a bother for any static components.)

##Set up

Clone the repo and install the node dependencies.

git clone https://github.com/Jon-Biz/simple-static-react-aframe
cd simple-static-react-aframe
npm i

##Usage

###Development

Run the npm script dev to develop.

npm run dev

A webpack server will now be running on 4000, serving the contents of the public directory. The entry files are in src - index.js and style.css.

NOTE: this is using webpack-dev-server, not actually overwriting the files in public. For that, you will need to run the build script.

###Production

Run the npm script 'build' to update style.css and index.js in the public directory. Upload this directory to your web server.

npm run build

simple-static-react-aframe's People

Contributors

jon-biz avatar ferologics avatar

Watchers

MUHAMMAD MANNIR AHMAD avatar  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.