@conclurer/edel-elements
TypeScript icon, indicating that this package has built-in type declarations

1.0.0-beta.44 • Public • Published

Edel-Elements

Documentation can be found at Github.io Page.

Edel-Context Element

A new, no UI element which could handle the context for an edel-element. There are some edel-elements (like the viewers) which need a context (endpoint/jwt/etc.). There are two options: Provide the context directly to every element, or using the context element.

The edel-context element is an HTML tag which accept endpoint and jwt as property and also triggers an event on every update of these properties. So if you want to listen to context updates, simply subscribe to the contextUpdated event.

Sample usage:

<edel-context endpoint="http://localhost:3000/graphql" jwt="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHBpcnkiOiIyMDE5LTAxLTE1VDEzOjU1OjI0LjQ2NloiLCJvcmdJZGVudGlmaWVyIjoiY29uY2x1cmVyIiwiZnFuIjoiYWFyb24uY3ppY2hvbkBjb25jbHVyZXIuY29tIiwidXNlcklkIjoiNjg0YTQ3MmUtZDQwMy00YzkzLWI3ZWMtMTUyYWJhZWE5NDdiIiwiaWF0IjoxNTQ3NDc0MTI0fQ.YGVTny5HCpDrzFIyZf_1yhKkyx1SfA8TfGbXzLf9gOQ"></edel-context>

The jwt property is also optional. If the edel-context element could find a jwt inside the localStorage this is also fine.

Readme

Keywords

none

Package Sidebar

Install

npm i @conclurer/edel-elements

Homepage

edelog.com

Weekly Downloads

2

Version

1.0.0-beta.44

License

Apache-2.0

Unpacked Size

9.88 MB

Total Files

669

Last publish

Collaborators

  • maehldom