Gathering detailed insights and metrics for miyojs-filter-conditions
Gathering detailed insights and metrics for miyojs-filter-conditions
npm install miyojs-filter-conditions
Typescript
Module System
Node Version
NPM Version
CoffeeScript (100%)
Total Downloads
2,197
Last Day
1
Last Week
2
Last Month
14
Last Year
79
1 Stars
5 Commits
3 Watching
1 Branches
1 Contributors
Minified
Minified + Gzipped
Latest Version
1.0.0
Package Id
miyojs-filter-conditions@1.0.0
Size
3.34 kB
NPM Version
2.1.3
Node Version
0.11.13
Cumulative downloads
Total Downloads
Last day
0%
1
Compared to previous day
Last week
-71.4%
2
Compared to previous week
Last month
180%
14
Compared to previous month
Last year
-41%
79
Compared to previous year
7
これは伺か用SHIORIサブシステムである美代(Miyo)の辞書フィルタプラグインです。
いわゆるswitch文を提供します。
npm install miyojs-filter-conditions
ghost/masterをカレントディレクトリとして同様に
npm install miyojs-filter-conditions
いわゆるswitch文を提供します。
このフィルタは以下に依存します。
propertyを読み込んだ上でproperty_initializeを一回実行した後で利用できます。
_load:
filters: [..., property_initialize, ...]
MiyoのYAML辞書ファイルのエントリにフィルタを追加します。
OnTest:
filters: [conditions]
argument:
conditions:
-
when.jse: this.variables.hoge == 1
do:
- \h\s[0]hoge = 1\e
- \h\s[0]hoge = 1!\e
-
when.coffee: @variables.hoge == 2
do:
filters: [conditions]
argument:
...
argument.conditionsを使います。
conditionsは配列で、それぞれの要素のwhenを評価し、真ならdoをエントリ内容として実行します。
whenはpropertyフィルタによる効果でwhen.[handler]という名前にするとコードとして評価することが出来ます。
breakのいらないswitch文のように、要素は順番どおりに評価され、最初に真となった要素のみが使われます。
whenのない要素は常に真と評価されるので、switch文のdefaultのように使うことが出来ます。
do内はエントリのトップレベル(たとえばOnTest:の直下)と同じように実行されます。 なので通常の発話等をおいたり、さらにfilterをかけることも可能です。
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
no SAST tool detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/5 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
license file not detected
Details
Reason
branch protection not enabled on development/release branches
Details
Score
Last Scanned on 2025-01-27
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More