# mithril-widgets

> It is built upon mithril.js and bulma.css.

Latest version **1.1.1** (published 2019-03-21) · MIT license · 0 weekly downloads

## Install

```sh
npm install mithril-widgets
pnpm add mithril-widgets
yarn add mithril-widgets
bun add mithril-widgets
```

## 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.1.1 |
| Published | 2019-03-21 |
| First published | 2019-03-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 934.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | pinkbanana |
| Maintainers | pinkbanana |
| Keywords | mithril, bulma, widgets |

## Links

- npm: https://www.npmjs.com/package/mithril-widgets
- Repository: https://github.com/lostpupil/mithril-widgets
- Homepage: https://github.com/lostpupil/mithril-widgets#readme
- Issues: https://github.com/lostpupil/mithril-widgets/issues
- npm.io page: https://npm.io/package/mithril-widgets

## Dependencies (4)

- [lodash](https://npm.io/package/lodash.md) ^4.17.11
- [fuse.js](https://npm.io/package/fuse.js.md) ^3.4.4
- [mithril](https://npm.io/package/mithril.md) ^1.1.6
- [sweetalert](https://npm.io/package/sweetalert.md) ^2.1.0

## Alternatives

- [@sveltejs/kit](https://npm.io/package/@sveltejs/kit.md) — 2.2M weekly downloads
- [@atlaskit/theme](https://npm.io/package/@atlaskit/theme.md) — 402.0K weekly downloads
- [@tangle-network/brand](https://npm.io/package/@tangle-network/brand.md) — 10.0K weekly downloads
- [seneca](https://npm.io/package/seneca.md) — 7.4K weekly downloads
- [@bsb/base](https://npm.io/package/@bsb/base.md) — 7.2K weekly downloads

## Recent versions

- 1.1.1 (latest) — 2019-03-21
- 1.1.0 — 2019-03-21
- 1.0.4 — 2019-03-21
- 1.0.3 — 2019-03-21
- 1.0.2 — 2019-03-21
- 1.0.1 — 2019-03-21
- 1.0.0 — 2019-03-21

## README

# Mithril Widgets

It is built upon mithril.js and bulma.css.

## Demo
[Demo](https://lostpupil.github.io/mithril-widgets)

## How to use

```javascript

import MithrilWidgets from 'mithril-widgets'
let tbl_headers = [{
    key: 'id',
    text: 'ID'
}, {
    key: 'username',
    text: "USERNAME"
}, {
    key: 'lorem',
    text: 'LOREM'
}]
let tbl_ds = [{
    id: 1,
    username: 'banana',
    lorem: 'blah'
}]

m(MithrilWidgets.simpleTable, {
    headers: tbl_headers,
    ds: tbl_ds
})

m(MithrilWidgets.simpleSearchTable, {
    headers: tbl_headers,
    ds: tbl_ds
})
```

## Widgets

### simpleTable

|property name | value | required|
|--------------|-------|--------|
|headers|vnode.attrs.headers|true|
|ds|vnode.attrs.ds|true |
|page|0|false|
|limit|vnode.attrs.limit(10)|false|


### simpleSearchTable

|property name | value | required|
|--------------|-------|--------|
|headers|vnode.attrs.headers|true|
|ds|vnode.attrs.ds|true|
|page|0|false|
|limit|vnode.attrs.limit(10)|false|
|q|input('')|false|

### remoteSearchTable

|property name | value | required|
|--------------|-------|--------|
|headers|vnode.attrs.headers|true|
|ds_url|vnode.attrs.ds_url|true|
|page|0|false|
|limit|vnode.attrs.limit(10)|false|
|has_prev|false|false|
|has_next|false|false|
|total_pages|0|false|

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