Skip to content

Commit 5088906

Browse files
committed
update
1 parent 9b69f33 commit 5088906

File tree

6 files changed

+115
-0
lines changed

6 files changed

+115
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Logs
2+
logs
3+
*.log
4+
5+
# Runtime data
6+
pids
7+
*.pid
8+
*.seed
9+
10+
# Directory for instrumented libs generated by jscoverage/JSCover
11+
lib-cov
12+
13+
# Coverage directory used by tools like istanbul
14+
coverage
15+
16+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
17+
.grunt
18+
19+
# node-waf configuration
20+
.lock-wscript
21+
22+
# Compiled binary addons (http://nodejs.org/api/addons.html)
23+
build/Release
24+
25+
# Dependency directory
26+
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
27+
node_modules
28+
bower_components
29+
#build result
30+
build
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import React from 'react';
2+
3+
class App extends React.Component {
4+
render() {
5+
return (
6+
<div>
7+
欢迎来到菜鸟教程学习!!!
8+
</div>
9+
);
10+
}
11+
}
12+
13+
export default App;
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
</head>
6+
<body>
7+
<div id="app"></div>
8+
<script src="index.js"></script>
9+
</body>
10+
</html>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/*
2+
* @Author: huangchengdu
3+
* @Date: 2017-01-05 21:08:25
4+
* @Last Modified by: huangchengdu
5+
* @Last Modified time: 2017-01-05 21:19:46
6+
*/
7+
8+
import React from 'react';
9+
import ReactDOM from 'react-dom';
10+
import App from './App.jsx';
11+
12+
ReactDOM.render(<App />, document.getElementById('app'))
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "runoob-react-test",
3+
"version": "1.0.0",
4+
"description": "",
5+
"main": "index.js",
6+
"scripts": {
7+
"start": "webpack-dev-server --hot"
8+
},
9+
"author": "huangchengdu",
10+
"license": "ISC",
11+
"dependencies": {
12+
"react": "^15.4.1",
13+
"react-dom": "^15.4.1"
14+
}
15+
}
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/*
2+
* @Author: huangchengdu
3+
* @Date: 2017-01-05 21:08:44
4+
* @Last Modified by: huangchengdu
5+
* @Last Modified time: 2017-01-05 21:21:22
6+
*/
7+
8+
var config = {
9+
entry: './main.js',
10+
11+
output: {
12+
path:'./',
13+
filename: 'index.js',
14+
},
15+
16+
devServer: {
17+
inline: true,
18+
port: 7777
19+
},
20+
21+
module: {
22+
loaders: [ {
23+
test: /\.jsx?$/,
24+
exclude: /node_modules/,
25+
loader: 'babel',
26+
27+
query: {
28+
presets: ['es2015', 'react']
29+
}
30+
}]
31+
}
32+
33+
}
34+
35+
module.exports = config;

0 commit comments

Comments
 (0)