# @dashkite/neon-breeze

> Web Component that combines the Breeze authentication API and Neon routing API

Latest version **1.0.1-beta.6** (published 2020-11-17) · SEE LICENSE IN LICENSE.md license · 0 weekly downloads

## Install

```sh
npm install @dashkite/neon-breeze
pnpm add @dashkite/neon-breeze
yarn add @dashkite/neon-breeze
bun add @dashkite/neon-breeze
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1-beta.6 |
| Published | 2020-11-17 |
| First published | 2020-08-14 |
| Weekly downloads | 0 |
| License | SEE LICENSE IN LICENSE.md |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 10 |
| Unpacked size | 16.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | freeformflow, dyoder |

## Links

- npm: https://www.npmjs.com/package/@dashkite/neon-breeze
- Repository: https://github.com/dashkite/neon-breeze
- Homepage: https://github.com/dashkite/neon-breeze#readme
- Issues: https://github.com/dashkite/neon-breeze/issues
- npm.io page: https://npm.io/package/@dashkite/neon-breeze

## Dependencies (10)

- [@dashkite/zinc](https://npm.io/package/@dashkite/zinc.md) 0.1.3
- [@dashkite/quark](https://npm.io/package/@dashkite/quark.md) 1.3.0-beta.4
- [@dashkite/carbon](https://npm.io/package/@dashkite/carbon.md) 4.1.0-beta.4
- [@dashkite/helium](https://npm.io/package/@dashkite/helium.md) ^0.3.0
- [@dashkite/katana](https://npm.io/package/@dashkite/katana.md) ^0.3.2
- [@dashkite/mercury](https://npm.io/package/@dashkite/mercury.md) 0.1.2
- [@pandastrike/garden](https://npm.io/package/@pandastrike/garden.md) ^8.0.1
- [@dashkite/mercury-sky](https://npm.io/package/@dashkite/mercury-sky.md) 0.0.6
- [@dashkite/mercury-zinc](https://npm.io/package/@dashkite/mercury-zinc.md) 0.1.3
- [@dashkite/breeze-client](https://npm.io/package/@dashkite/breeze-client.md) 1.0.4-beta.3

## Recent versions

- 1.0.1-beta.6 (latest) — 2020-11-17
- 1.0.1-beta.5 — 2020-10-17
- 1.0.1-beta.4 — 2020-10-16
- 1.0.1-beta.3 — 2020-10-15
- 1.0.1-beta.2 — 2020-10-15
- 1.0.1-beta.1 — 2020-10-07
- 1.0.1 — 2020-09-11
- 1.0.0 — 2020-09-09
- 0.7.0 — 2020-09-01
- 0.6.0 — 2020-08-31
- 0.5.0 — 2020-08-27
- 0.4.0 — 2020-08-14
- 0.1.0 — 2020-08-14

## README

# Neon Breeze
Web Component that combines the Breeze authentication API and Neon routing API

## Install

```
npm i @dashkite/neon-breeze
```

## Usage

Neon-Breeze includes:

- A Web Component for displaying HX for your app's interface with the Breeze API. The component contains a graph for dealing with OAuth login cases by wrapping the lower-level Breeze Client.
- Designed to work well with the Neon page generation and Oxygen routing interfaces.

To use the component, simply import `@dashkite/neon-breeze` and render the component using the `neon-breeze` tag.

To handle the OAuth redirect, add an appropriate route and call combinators to access Breeze API resources, depending on the circumstances.

### Helium Configuration

The Breeze Client uses `@dashkite/helium` to reference singleton configuration across the application modules.

#### configuration:breeze

```yaml
api: URL for the Breeze API or compatible.
authority: Name of the capability authority.
redirectURL: Return URL when redirected back from OAuth identity provider.
entry: Name for the entry tag the application profile is stored under.
entryDisplayName: Human-friendly name of the entry.
postSuccessPage: Name of the page to route after successful login.
```

#### profiles:application

The high-level Zinc profile management interface. Modulization and naming is TBD.

### Example: Login From OAuth redirect

This component is designed to be high-level and super simple to use. Place the neon-breeze tag into your markup and give it the Breeze identity token as a data attribute. It will render and handle HX flow cases automatically for you.

```coffeescript
import {wrap, tee, pipe, flow} from "@pandastrike/garden"
import * as k from "@dashkite/katana"
import * as n from "@dashkite/neon"
import Registry from "@dashkite/helium"
import header from "templates/header.pug"
import {standard} from "../helpers"
import p from "profiles/hype"

router = Registry.get "router"

token = ({bindings}) -> bindings.token

router.add "/oauth{?parameters*}",
  name: "oauth"
  flow [
    n.properties
      title: -> "Hype: Validating OAuth Authentication"
      description: -> "This page validates your authentication from an OAuth provider and associates or retrieves your Hype profile for you."

    standard

    n.view "main", ({parameters: {token}}) ->
      "<neon-breeze data-token = '#{token}' />"

    n.show
  ]

```

---
_Source: https://npm.io/package/@dashkite/neon-breeze · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
