1.0.1 • Published 4 years ago

portal-web-components v1.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

This component was bootstrapped with Direflow.

Jolt Web Component

This project is created using Direflow

to install just yarn add @jolt-us/web-components

creating new web component:

  • create a new folder src/direflow-components/cool-component * notice the syntax
  • create index.tsx file and inside write
       import createWebComponent from "../../GlobalComponents/setup/createWebComponent";
       import CoolComponent from "./CoolComponent";
       
       
       export default createWebComponent("cool-component", CoolComponent)
 - and that is it create your file `src/direflow-components/cool-component/CoolComponent.tsx` <br>
 and start develop your web-component.
 
 #### debugging:
 - notice there is a `public/index.html` file. this file is for debuging purposes.
 - just add inside the `body` `<body><cool-component /></body>` 
 - now run `yarn dev` and lok at `http://localhost:3020`
 this file is on git ignore so we can change it as we like.<br>
 _**if you do a change in that file that everyone should use.<br> 
 please remember to remove it from git ignore, commit it and put it again**_
 
 
 #### deployment
   - run `yarn build && yarn publish`
   - go to `jolt-public-web-app` and increase the npm dependency version.