An open API service indexing awesome lists of open source software.

https://github.com/bahrus/be-hydrated


https://github.com/bahrus/be-hydrated

Last synced: 3 months ago
JSON representation

Awesome Lists containing this project

README

        

# be-hydrated

*be-hydrated* is a DOM (custom) element decorator / behavior. It assists with hydrating nearby elements.

[![NPM version](https://badge.fury.io/js/be-hydrated.png)](http://badge.fury.io/js/be-hydrated)
[![How big is this package in your project?](https://img.shields.io/bundlephobia/minzip/be-hydrated?style=for-the-badge)](https://bundlephobia.com/result?p=be-hydrated)

## Hemingway Notation

Configuring be-hydrated can be done as a combination of two notation styles: JavaScriptObjectNotation, and/or what we refer to as ["Hemingway Notation"](https://bookanalysis.com/ernest-hemingway/writing-style/):

```html


30

```

*be-hydrated* can adorn both template and script elements, whichever is more convenient.

The JSON equivalent, discussed later[TODO], may be more convenient for the JavaScript crowd who prefer editing a pre-build *.mts/*.mjs file that compiles to *.html, benefitting from TypeScript compile checks.

Hemingway notation is more optimized for regular Joe's and Jill's editing HTML files. It is the equivalent of markdown for JavaScript.

## Underneath the surface

The configuration above is shorthand for:

```html


30

```

Breaking down the (hidden) meaning further, the configuration above is shorthand for:

```html


30

```

each of which is described in more detail:

1. [be-derived](https://github.com/bahrus/be-derived)
2. [be-eventful](https://github.com/bahrus/be-eventful)
3. [be-sharing](https://github.com/bahrus/be-sharing)