Answers for "set background image in material ui"


set background image in material ui

import React from 'react';

import Paper from 'material-ui/Paper';

import IconButton from 'material-ui/IconButton';
import ActionHome from 'material-ui/svg-icons/action/home';

import Image from '../img/main.jpg'; // Import using relative path

const styles = {
    paperContainer: {
        backgroundImage: `url(${Image})`

export default class Home extends React.Component{
            <Paper style={styles.paperContainer}>
                Some text to fill the Paper Component
Posted by: Guest on April-27-2020

Code answers related to "set background image in material ui"

Code answers related to "Javascript"

Browse Popular Code Answers by Language