npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@kexi/uiflow

v2.1.1

Published

uiflow - the simplest way to write down your ui-flow diagram like markdown

Downloads

40

Readme

codecov

uiflow

マークダウン風のテキストからUI Flowsのグラフを生成するコンパイラ

UI Flowsとは?

Webサイトやスマホアプリなどのユーザーインタフェースを設計する際に、より簡単な表現で全体の流れを記述する次のような図のことです。

simple.png

具体的なUI設計に触れず、

  • ユーザーが見るもの
  • ユーザーがする行動

に注目することでシンプルにUIの必要条件、あるいは骨子を記述することができます。

uiflowコンパイラは、次のような簡潔な表現でこのような図を作図することができます。

[最初に]
ユーザーが見るものを書きます。
--
ユーザーがする行動を書きます。

[次に]
ユーザーが見るもの
--
ユーザーがすること1
==> その結果1
ユーザーがすること2
==> その結果2

[その結果1]
結果

[その結果2]
結果

コマンドの使い方

シンプルな使い方

uiflow -i myapp.txt -o myapp.dot -f dot  

myapp.txtをdot形式で、myapp.dotに変換する。

uiflow形式の文法

基本ブロック

[ページ名]
表示要素1
表示要素2
表示要素3
--
行動要素1
===> 遷移先ページ1名
行動要素2
===> 遷移先ページ2名

base.png

基本ブロックをつなげる

[ページ名]
表示要素1
--
行動要素1

[ページ名2]
表示要素
--
行動要素

[ページ名3]
表示要素
--
行動要素

行動要素の==>を省略すると次の基本ブロックに自動的につながります。

base.png

遷移に名前をつける

=={hogehoge}=>と表記して、遷移に名前をつけることができます。

[最初に]
ユーザーが見るものを書きます。
--
ユーザーがする行動を書きます。

[次に]
ユーザーが見るもの
--
ユーザーがすること1
=={遷移アクション名}=> その結果1
ユーザーがすること2
=={API名など}=> その結果2

[その結果1]
結果

[その結果2]
結果

simple-graph.png

少し複雑な例


[初回通知]
通知の確認ダイアログ
--
OK

[国選択]
リージョンの選択
デフォルトで日本
OKボタン
--
OK

[はじめよう]
ヒント情報
はじめるボタン
--
ヒントをスワイプ
==> はじめよう
LINEQを始める

[非ログインメイン画面]
ログインすると全ての機能を使えますアラート
フィード
通知アイコン
検索アイコン
ホーム
分野
Qボタン
ランキング
マイページ(N)
------
アラートをタップ
==> 利用規約
分野をタップ
==> 分野
Qボタンをタップ
==> ログイン確認
ランキングをタップ
==> ランキング


[利用規約]
利用規約の表示

[分野]
分野詳細

[ランキング]
ランキング詳細

base.png

uiflowをライブラリとして使う

次のように使うことができます。

const uiflow = require("@kexi/uiflow");

SEE ALSO