This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Organization = artifacts.require("Organization"); | |
contract('Organization', (accounts) => { | |
let contractInstance; | |
const creator = accounts[0]; | |
beforeEach(async function () { | |
contractInstance = await Organization.new(4, 4, { from: creator }); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { Header, Button, Grid } from 'semantic-ui-react'; | |
import { withRouter } from 'react-router-dom'; | |
import './home.css'; | |
import { Connect, SimpleSigner } from 'uport-connect'; | |
import * as actions from '../../actions'; | |
import { uport } from '../../utils/connector'; | |
import { connect, } from 'react-redux'; | |
const MNID = require('mnid'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Connect, SimpleSigner } from 'uport-connect' | |
import OrganizationContract from '../build/Organization.json'; | |
//modify according to you information from uPort | |
export const uport = new Connect('dapp-workshop', { | |
clientId: '2onBp3mzTkqL6yYScbJdAj1BmyNXarWX5sT', | |
network: 'rinkeby', | |
signer: SimpleSigner('f8ee568811f011ba93b5cd7105dbdd25d9de2d34ace72ffd6c909ea79a4ff2e2') | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
h1.ui.center.aligned.header{ | |
color: #6BB547; | |
margin:1em; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import './layout.css'; | |
import { Container, Grid, Header } from 'semantic-ui-react'; | |
function withLayout(WrappedComponent) { | |
return class extends React.Component { | |
constructor(props) { | |
super(props); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { Switch, Route, BrowserRouter as Router } from 'react-router-dom'; | |
import Home from './containers/Home'; | |
import NewProposal from './containers/NewProposal'; | |
import ProposalDetail from './containers/ProposalDetail'; | |
import Proposals from './containers/Proposals'; | |
import Results from './containers/Results'; | |
const Routes = () => ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import './layout.css'; | |
import { Container, Grid, Header } from 'semantic-ui-react'; | |
function withLayout(WrappedComponent) { | |
return class extends React.Component { | |
constructor(props) { | |
super(props); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import PropTypes from 'prop-types' | |
import Routes from './Routes'; | |
import { Provider } from 'react-redux'; | |
import './App.css'; | |
class App extends React.Component { | |
render() { | |
return ( | |
<Provider className="app" store={this.props.store}> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import ReactDOM from 'react-dom'; | |
import { createStore, applyMiddleware } from 'redux'; | |
import reduxThunk from 'redux-thunk'; | |
import reducers from './reducers'; | |
import App from './App'; | |
const createStoreWithMiddleware = applyMiddleware(reduxThunk)(createStore); | |
const store = createStoreWithMiddleware(reducers); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { Switch, Route, BrowserRouter as Router } from 'react-router-dom'; | |
import Home from './containers/Home'; | |
import NewProposal from './containers/NewProposal'; | |
import ProposalDetail from './containers/ProposalDetail'; | |
import Proposals from './containers/Proposals'; | |
import Results from './containers/Results'; | |
import withLayout from './containers/Layout'; |