in react to show component?
I want to show ui with that package
I don't understand what you are actually trying to say.
I want to make a package in reactjs which has a ui page like auth page. And i want to use it again and again in my future projects by simply adding that package. Like import {Authentication} from 'auth-package' Then return <Authentication />; How can i make this kind of package. Is there's any example reference which can be helpful?
you have two options. 1. create a separate file for that component and copy and paste it every project you need it. 2. create npm package of that component and install it. https://stackoverflow.com/questions/46166381/how-can-i-export-a-react-component-as-an-npm-package-to-use-in-separate-projects
Обсуждают сегодня