# @bemto/core

> This is an ongoing dev version, do not use in your projects unless you really know what you're doing, thanks.

Latest version **0.1.0-alpha.6** (published 2019-06-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install @bemto/core
pnpm add @bemto/core
yarn add @bemto/core
bun add @bemto/core
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0-alpha.6 |
| Published | 2019-06-03 |
| First published | 2019-05-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 21.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Roman Komarov |
| Maintainers | kizu |

## Links

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

## Recent versions

- 0.1.0-alpha.6 (latest) — 2019-06-03
- 0.1.0-alpha.5 — 2019-05-27
- 0.1.0-alpha.4 — 2019-05-27
- 0.1.0-alpha.3 — 2019-05-24
- 0.1.0-alpha.2 — 2019-05-17
- 0.1.0-alpha.1 — 2019-05-17

## README

# Bemto core

This is an ongoing dev version, do not use in your projects unless you really know what you're doing, thanks.

## Install

```sh
npm install @bemto/core
```

```sh
yarn add @bemto/core
```

## Basic Usage

In the most basic form, bemto accepts a list of “props”, and returns an object containing a `getProps` function that then could be used to access the resulting props for the block itself and for all the elements.

``` js
import bemto from '@bemto/core'

// Imagine we have `props` with some props
const { getProps } = bemto(props);

getProps(); // would return a list of props for the root element.
getProps('__Content'); // would return a list of props for the Content element.
```

If you'd want to use bemto in a JSX-like context, you can use this method alongside object spread to retrieve all the needed props for your HTML elements:

``` jsx
<div {...getProps()}>
  <div {...getProps('__Content')}>
    …
  </div>
</div>
```

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