File tree 3 files changed +7
-7
lines changed 3 files changed +7
-7
lines changed Original file line number Diff line number Diff line change 4
4
"url" : " https://github.com/textlint-ja/textlint-rule-no-dropping-i/issues"
5
5
},
6
6
"dependencies" : {
7
- "kuromojin" : " ^1.2 .1" ,
7
+ "kuromojin" : " ^2.1 .1" ,
8
8
"textlint-rule-helper" : " ^1.1.4"
9
9
},
10
10
"description" : " い抜き言葉を検出するtextlint rule" ,
Original file line number Diff line number Diff line change 1
1
// LICENSE : MIT
2
2
"use strict" ;
3
3
import { RuleHelper } from "textlint-rule-helper" ;
4
- import kuromojin from "kuromojin" ;
4
+ import { tokenize } from "kuromojin" ;
5
5
6
6
function isTargetWord ( token ) {
7
7
return token . pos == "助詞" && token . pos_detail_1 == "接続助詞" && token . basic_form == "て" ;
@@ -20,7 +20,7 @@ module.exports = function(context) {
20
20
return ;
21
21
}
22
22
let text = getSource ( node ) ;
23
- return kuromojin ( text ) . then ( tokens => {
23
+ return tokenize ( text ) . then ( tokens => {
24
24
tokens . reduce ( ( prev , current ) => {
25
25
if ( isTargetWord ( prev ) && isMasuWord ( current ) ) {
26
26
report (
Original file line number Diff line number Diff line change @@ -2928,10 +2928,10 @@ kuromoji@0.1.1:
2928
2928
doublearray "0.0.2"
2929
2929
zlibjs "^0.2.0"
2930
2930
2931
- kuromojin@^1.2 .1 :
2932
- version "1.5 .1"
2933
- resolved "https://registry.yarnpkg.com/kuromojin/-/kuromojin-1.5. 1.tgz#f5c4cc2d4a8b56343c7281f7def8d56309184078 "
2934
- integrity sha512-tzt3UUqWqzwHMsahchyrcs9kgbn6OM7xP4QRCd0w5vqE0lA/cjCH0OxjLaekz5cnxGmcy8RfN7La3xOxZOvJ1w ==
2931
+ kuromojin@^2.1 .1 :
2932
+ version "2.1 .1"
2933
+ resolved "https://registry.yarnpkg.com/kuromojin/-/kuromojin-2.1. 1.tgz#5de1dbec4ffcc7cce57a10e75e751cd1ca384e38 "
2934
+ integrity sha512-bd5dfE9CdRBoRPiquE5uhzBrDOn2K3WuFeOWqZgM7DNtQhvS7P9IALy5MtDxXcnw7DLBAZ1A7DByPO5BhXdgew ==
2935
2935
dependencies :
2936
2936
kuromoji "0.1.1"
2937
2937
You can’t perform that action at this time.
0 commit comments