pickupbiz-inputbox
v1.0.1
Published
pickupbiz-inputbox for design experience Component for npm
Downloads
5
Maintainers
Readme
Install package : npm i pickupbiz-inputbox
Import component by using - import Inputbox from "pickupbiz-inputbox";
Declare the data useState:
const [data, setData] = useState(""); const handleChange = (d) => { setData(d); };
Handle Change : const handleChange = (d) => { setData(d); };
Implement Input Box by passing properties: <Inputbox label="Enter Name Here:" onChange={handleChange} styles={{ label: { fontFamily: "Comic Sans MS", color: "brown", }, }} />
Use Sample Code:
import React, { useState } from "react"; import Inputbox from "pickupbiz-inputbox";
function App() { const [data, setData] = useState(""); const handleChange = (d) => { setData(d); }; return ( <React.Fragment> <Inputbox label="Enter Name Here:" onChange={handleChange} styles={{ label: { fontFamily: "Comic Sans MS", color: "brown", }, }} />
export default App;
1.Register To npm 2.Run npm init command 3.Provide the required parameter in all small letters 4.Provide the default entry point for app. Default selection would be index.js 5.Put your logic in index.js 5.5. npm adduser 6. npm login (username,Password and email) 7.Run npm publish.
ReferenceLink : https://jasonwatmore.com/post/2018/04/14/react-npm-how-to-publish-a-react-component-to-npm