@eldarlabs/cycle-ui

中文文档
0.7.0发布于 2016/04/22MITCommonJS近 30 天下载 2396

Cycle UI Components library

原始使用文档
文档目录4 节
  1. How to use
  2. Entitlement
  3. Feedback
  4. Related projects

eldarlabs/cycle-ui

circleci build version bitHound Overall Score MIT License semantic-release

A Cycle.js HTML component library.

##Demonstration Site

An experimental work in progress conversion of the Material Design react-toolbox components to Cycle.js components. The styles from react-toolbox are written with PostCSS. Future work may define an interface for interchangeable styles.

How to use

The easiest way to get started is to clone the cycle-ui-typescript-webpack starter project. It includes a Cycle-UI kitchen sink demo (demonstration site). Start modifying the starter project or get some ideas for how to use Cycle-UI in your own project.

Note: I want to bring a proposal to Cycle-DOM to allow removal of the .DOM boilerplate.

// Import components you want to use
import { Input, RadioButton } from '@eldarlabs/cycle-ui';

// Use components in your Cycle.js view

return div([
  h3('.example', [`Using Cycle-UI`]),
  Input(sources, {
      label: `Answer to life`,
      maxLength: 50,
  }).DOM,
  RadioButton(sources, {
    label: 'Radio easy',
    checked: true,
  }).DOM,
])

Entitlement

This project is open source so team members can share knowledge and learn from the community. Using this software does not entitle you to any support or right to demand features. See below for how to contribute.

Feedback

Let is know of any Issues. Pull requests will be considered.

  • cycle-ui-typescript-webpack - Cycle.js Starter Project for using Cycle-UI, TypeScript and WebPack.
  • Cycle.js - required to use the Cycle-UI components. Declarative programming with data flow.
  • React Toolbox Components - uses the PostCSS/SASS styles from this library.
  • Snabbdom - a virtual DOM library
  • cycle-snabbdom - a Cycle.js DOM library that uses the Snabbdom virtual DOM.
  • RxJS - Functional, Reactive, Observable streams of data that power Cycle.js
  • TypeScript - Types, Interfaces, static checking and other good stuff.
  • Typings - Trying to make TypeScript Type definitions easier to deal with.
  • Semantic Release - Trying out this tool for streamlining a release.
  • Commitizen - Commit tool that works well with Semantic Release.

License

The MIT License

Copyright (c) 2016 Eldar Labs

版本与发布记录

@eldarlabs/cycle-ui 共发布 20 个版本,首次发布于 2016/02/29;过去 12 个月发布了 0 个版本。

版本发布日期距今
0.7.0latest2016/04/2210 年前
0.6.32016/04/1710 年前
0.6.22016/04/1510 年前
0.6.12016/04/1510 年前
0.6.02016/04/1310 年前
0.5.32016/04/1110 年前

其他发布通道:alpha → 0.0.3。

关于 @eldarlabs/cycle-ui 的常见问题

@eldarlabs/cycle-ui 是什么?

Cycle UI Components library

如何安装 @eldarlabs/cycle-ui?

在项目目录运行 npm install @eldarlabs/cycle-ui,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:@cycle/core(^6.0.0)、@cycle/isolate(^1.2.0)、cycle-snabbdom(^1.2.1)、react-toolbox(0.16.2)、rx(^4.1.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@eldarlabs/cycle-ui 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/eldarlabs__cycle-ui 是否存在。

@eldarlabs/cycle-ui 支持 ESM 还是 CommonJS?

以 CommonJS 形式发布,可以直接 require();在 ES Module 项目中也可以用 import 引入(Node.js 会把 module.exports 作为默认导出)。

@eldarlabs/cycle-ui 可以商用吗?

@eldarlabs/cycle-ui 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@eldarlabs/cycle-ui 的下载量有多少?

根据 npm 官方下载统计,@eldarlabs/cycle-ui 在 2026/10/14 – 2026/11/12 这 30 天内被下载 2,396 次,日均约 80 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@eldarlabs/cycle-ui 还在维护吗?

最新版本 0.7.0 发布于 2016/04/22(10 年前);至今共发布 20 个版本,其中过去 12 个月发布了 0 个;首次发布于 2016/02/29。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。