Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Add webpack example #421

Merged
merged 1 commit into from
Nov 17, 2016
Merged

Conversation

victorb
Copy link
Contributor

@victorb victorb commented Nov 14, 2016

Comes from https://github.com/VictorBjelkholm/webpack-node-ipfs-api-demo which I'll deprecate if we decide to merge this.

Copy link
Contributor

@dignifiedquire dignifiedquire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you :) let some comments

"browser": true,
"esnext": true,
"newcap": false
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we really need jshint and eslint?

@@ -0,0 +1,42 @@
{
"name": "react-hot-boilerplate",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets rename this properly

{
"name": "react-hot-boilerplate",
"version": "1.0.0",
"description": "Boilerplate for ReactJS project with hot code reloading",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can update this as well

"edit",
"webpack"
],
"author": "Dan Abramov <dan.abramov@me.com> (http://github.com/gaearon)",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think Dan wrote this ;)

import ipfsAPI from 'ipfs-api'

var ipfs = ipfsAPI('localhost', '5001')
const stringToUse = 'Hello World From Webpack'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets make it hello world from wepbacked IPFS

})
ipfs.dht.findprovs(hash, (err, res) => {
if (err) throw err
console.log('found provs!')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not write this to the dom like the others do?

@victorb
Copy link
Contributor Author

victorb commented Nov 17, 2016

@dignifiedquire thanks for the review. The example comes from a quick setup I did, coming from Dan's react hot boilerplate. I'll address the things you've mentioned, and also remove the findprovs part (since it's out of scope of the example). Thanks!

@daviddias
Copy link
Contributor

Sweeeet! :D

Can we call the folder bundle-webpack so that then we also have bundle-browserify?

Also, can you add a README just explaining what people are doing with all of this pieces? Or even just say? "Copy this to your workspace and you get it working by running X Y Z commands"

@victorb
Copy link
Contributor Author

victorb commented Nov 17, 2016

@diasdavid you got it! 👍

@daviddias
Copy link
Contributor

awesome. Also update the readme section https://github.com/ipfs/js-ipfs-api#in-a-web-browser-through-browserify to point to both examples :)

@victorb victorb force-pushed the add-webpack-example branch 2 times, most recently from 90fe45b to 397c816 Compare November 17, 2016 11:31
@victorb
Copy link
Contributor Author

victorb commented Nov 17, 2016

Thanks for the feedback, everything have been addressed now!

@diasdavid @dignifiedquire please take a look again and merge if 👍

@victorb victorb force-pushed the add-webpack-example branch 3 times, most recently from 0a729c2 to 2cea58b Compare November 17, 2016 11:34
Copy link
Contributor

@daviddias daviddias left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did linting pass?
Overall LGTM

@victorb
Copy link
Contributor Author

victorb commented Nov 17, 2016

@diasdavid linting should pass now, yes.

@daviddias daviddias merged commit bc74839 into ipfs-inactive:master Nov 17, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants