Skip to content
This repository has been archived by the owner on Jan 1, 2024. It is now read-only.

Commit

Permalink
feat(src/common): require images with url-loader
Browse files Browse the repository at this point in the history
  • Loading branch information
Metnew committed Jul 15, 2017
1 parent 869a8e1 commit 679cdf0
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/common/components/views/Sidebar/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export default class SidebarComponent extends Component {
<StyledSidebar {...sidebarProps}>
<SidebarLogoContainer href="https://github.com/Metnew/react-semantic.ui-starter">
<SidebarLogo
src="./images/logo.png"
src={require('images/logo.png')}
alt="logo"
shape="circular"
centered
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import React, {PureComponent} from 'react'
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import {Card, Image, Button} from 'semantic-ui-react'

export default class DashboardCardComponent extends PureComponent {
export default class DashboardCardComponent extends Component {
static propTypes = {
title: PropTypes.string,
body: PropTypes.string,
Expand All @@ -12,10 +12,9 @@ export default class DashboardCardComponent extends PureComponent {

render () {
const {title, body, id} = this.props

return (
<Card raised>
<Image alt="Dummy image" src="./images/dummy.png" />
<Image alt="Dummy image" src={require('images/dummy.png')} />
<Card.Content>
<Card.Header>
{title}
Expand Down
2 changes: 1 addition & 1 deletion src/common/containers/UsersItem/components/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class UsersItemComponent extends Component {
const {user} = this.props
return (
<Card>
<Image alt={`${user.name}`} src="./images/daniel.jpg" />
<Image alt={`${user.name}`} src={require('images/daniel.jpg')} />
<Card.Content>
<Card.Header>
{user.name}
Expand Down

0 comments on commit 679cdf0

Please sign in to comment.