Скопировать все файлы в одну папку.
Установить http-server, если ещё не установлен:
npm install -g http-server
Запустить сервер:
| import React, { Component } from "react"; | |
| import { render } from "react-dom"; | |
| import "./index.css"; | |
| class Widget extends Component { | |
| state = { text: "" }; | |
| handleChange = (e) => { | |
| this.setState({ text: e.target.value }); | |
| }; | |
| render() { |
| /* ******************************************************************************************* | |
| * THE UPDATED VERSION IS AVAILABLE AT | |
| * https://github.com/LeCoupa/awesome-cheatsheets | |
| * ******************************************************************************************* */ | |
| // 0. Synopsis. | |
| // http://nodejs.org/api/synopsis.html |
(Full description and list of commands at - https://npmjs.org/doc/index.html)
##List of less common (however useful) NPM commands
######Prepand ./bin to your $PATH Make sure to export your local $PATH and prepand relative ./node_modules/.bin/:
The git command-line utility has plenty of inconsistencies http://steveko.wordpress.com/2012/02/24/10-things-i-hate-about-git/
A GUI like http://sourcetreeapp.com is often helpful, but staying on the command line usually quicker. This is a list of the commands I use most frequently, listed by funcional category:
git status list which (unstaged) files have changed