@skivy71/add-stakeholder
v1.0.1
Published
## Introduction
Downloads
2
Readme
Request Network Add Stakeholder Web Component
Introduction
This repo contains a collection of Web Components which you can quickly embed in other projects and leverage the features they provide.
Installation
Node
# import the library for build time development
npm i @requestnetwork/add-stakeholder
Browser
<script
src="//unpkg.com/@requestnetwork/add-stakeholder">
</script>
Usage
Node
import('@requestnetwork/add-stakeholder') // dynamic import of web component on parent render
import AddStakeholder from '@requestnetwork/add-stakeholder' // static import of web component
import addStakeholder from '@requestnetwork/add-stakeholder/src/components/add-stakeholder.svelte' // import as svelte component
Browser
<script src="./add-stakeholder/dist/components.umd.cjs" defer></script>
<add-stakeholder
builderKey="..."
webookUrl="..."/>
Developing
Install dependencies
npm i
Run the dev server
npm run dev
The web component source can be found in ./src/components/.svelte.
This file is imported into the local ./src/routes/+page.svelte for development purposes.
You can build the component via
npm run build:wc
The build process creates a component files to ./dist in both ESM and UMD format.