Showing posts with label EXPORT COMPONENT. Show all posts
Showing posts with label EXPORT COMPONENT. Show all posts

Monday, December 18, 2023

Multiple function component use and EXPORT COMPONENT in SINGLE JSX FILE

December 18, 2023 0

Multiple function component use and EXPORT COMPONENT 

in SINGLE JSX FILE 


एक ही फाइल (FILE)  में दो कंपोनेंट का उपयोग कैसे करें :-

और निर्यात (EXPORT) कैसे करें का उपयोग करें : -




import React from 'react';
import { Typography } from "@mui/material";

const Headingtypography = ({ name }) => {  
    return (
        <>
            <Typography variant="h6" sx={{ fontFamily: 'Roboto', fontWeight: 'bold', color: 'black' }} gutterBottom>      
                {name}
            </Typography>
        </>
    );
}

const Subheading = ({ name }) => {  
    return (
        <>
            <Typography variant="h6" sx={{ fontFamily: 'Roboto', fontWeight: 'bold', color: 'black' }} gutterBottom>      
                {name}
            </Typography>
        </>
    );
}

export { Headingtypography, Subheading };

Single function component use and EXPORT COMPONENT in SINGLE JSX FILE

December 18, 2023 0

 Single function component use


// Like as Text Widget

एक ही फाइल (FILE)  में  कंपोनेंट का उपयोग कैसे करें :-

                                        &

निर्यात (EXPORT) कैसे करें का उपयोग करें : -




import React from 'react';
import { Typography } from "@mui/material";

const Headingtypography = ({name}) => {  
    return (
        <>
            <Typography variant="h6" sx={{ fontFamily: 'Roboto', fontWeight: 'bold', color: 'black' }} gutterBottom>      
            {name}
            </Typography>
        </>
    );
}

export default Headingtypography;