From 46a2e6fb9fc1d875df1a6b2e0b11a01e42e72910 Mon Sep 17 00:00:00 2001 From: Stephen Grider Date: Sat, 23 May 2015 13:20:16 -0700 Subject: [PATCH 1/2] Update package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 5c1bc8b..190ce12 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "thumbnail-gulp", + "name": "react-starter", "version": "1.0.0", "main": "index.js", "scripts": { From 91815792536164e94caeca8a26a91815f7bc4efa Mon Sep 17 00:00:00 2001 From: Stephen Grider Date: Wed, 27 May 2015 22:56:41 -0700 Subject: [PATCH 2/2] Delete application.js --- application.js | 55 -------------------------------------------------- 1 file changed, 55 deletions(-) delete mode 100644 application.js diff --git a/application.js b/application.js deleted file mode 100644 index 0a87d73..0000000 --- a/application.js +++ /dev/null @@ -1,55 +0,0 @@ -var options = { - thumbnailData: [{ - title: 'Show Courses', - number: 12, - header: 'Learn React', - description: 'React is a fantastic new front end library for rendering web pages. React is a fantastic new front end library for rendering web pages.', - imageUrl: 'https://raw.githubusercontent.com/wiki/facebook/react/react-logo-1000-transparent.png' - },{ - title: 'Show Courses', - number: 25, - header: 'Learn Gulp', - description: 'Gulp will speed up your development workflow. Gulp will speed up your development workflow. Gulp will speed up your development workflow.', - imageUrl: 'http://brunch.io/images/others/gulp.png' - }] -}; - -var element = React.createElement(ThumbnailList, options); -React.render(element, document.querySelector('.container')); - -var Badge = React.createClass({displayName: "Badge", - render: function() { - return React.createElement("button", {className: "btn btn-primary", type: "button"}, - this.props.title, " ", React.createElement("span", {className: "badge"}, this.props.number) - ) - } -}); - -var ThumbnailList = React.createClass({displayName: "ThumbnailList", - render: function() { - var list = this.props.thumbnailData.map(function(thumbnailProps){ - return React.createElement(Thumbnail, React.__spread({}, thumbnailProps)) - }); - - return React.createElement("div", null, - list - ) - } -}); - -var Thumbnail = React.createClass({displayName: "Thumbnail", - render: function() { - return React.createElement("div", {className: "col-sm-6 col-md-4"}, - React.createElement("div", {className: "thumbnail"}, - React.createElement("img", {src: this.props.imageUrl, alt: "..."}), - React.createElement("div", {className: "caption"}, - React.createElement("h3", null, this.props.header), - React.createElement("p", null, this.props.description), - React.createElement("p", null, - React.createElement(Badge, {title: this.props.title, number: this.props.number}) - ) - ) - ) - ) - } -});