Upgrade to Pro — share decks privately, control downloads, hide ads and more …

vue.jsで漢字のふりがな自動変換を実装した話

02886e95c50822b9aa2552da1e518491?s=47 Takayuki
September 17, 2021

 vue.jsで漢字のふりがな自動変換を実装した話

vue.jsで漢字のふりがな自動変換を実装した話

02886e95c50822b9aa2552da1e518491?s=128

Takayuki

September 17, 2021
Tweet

Transcript

  1. vue.jsで漢字のふりがな自動ม換を ࣮૷した話 鈴木孝之

  2. "HFOEB ࣗݾ঺հ ࣮ݱ͔ͨͬͨ͠࢓༷ ࣮ࡍʹ࣮૷ͨ͠ߏ੒

  3. ࣗݾ঺հɾձࣾ঺հ

  4. Copyright Re:Build.inc All Rights Reserved. ࣗݾ঺հ 1 ◆໊લ ླ໦ ޹೭(Suzuki

    Takayuki) ※ಉ੏ಉ໊ଟͯ͘ࠔͬͯ·͢ɻɻɻ ◆ࣗݾ঺հ ɾ1990೥ੜ·Εɻ ɾԭೄͰىۀͯ͠໿3೥ɻ ɾPHPΧϯϑΝϨϯεԭೄ࣮ߦҕһ௕ɺ ϑϩϯτΤϯυΧϯϑΝϨϯεԭೄ࣮ߦҕһ௕ ◆झຯ ίεϓϨɺԻָϥΠϒɺϚϥιϯେձʹग़Δɺ໺ٿ؍ઓ BDD(Ϗʔνۦಈ։ൃ)
  5. Copyright Re:Build.inc All Rights Reserved. ࣗݾ঺հ 1

  6. Copyright Re:Build.inc All Rights Reserved. ձࣾ঺հ 1 ◆ձ໊ࣾ גࣜձࣾRe:Build ◆ॅॴ

    ԭೄݝಹ೼ࢢٱໜ஍2-2-2 λΠϜεϏϧ ◆ࣄۀ಺༰ ɾࣗࣾWEBαʔϏεͷاըɾ։ൃɻ ɾडୗ։ൃ ◆ࣾһ 10໊ ◆ΤϯδχΞͷಇ͖ํ ϦϞʔτϫʔΫՄೳͳࣗ༝ͳಇ͖ํΛਪ঑ͯ͠·͢ʂ
  7. Copyright Re:Build.inc All Rights Reserved. 7 ɾαʔϏε໊ Tadoru
 https://tadoru.work/
 


    ɾγεςϜ֓ཁ ΤϯδχΞಛԽܕͷ ϦϑΝϥϧ Ϋϥ΢υιʔγϯά 1 ձࣾ঺հ
  8. Copyright Re:Build.inc All Rights Reserved. 8 ɾαʔϏε໊ Re:Build Boot Camp


    https://rebuild-bootcamp.jp/
 
 ɾ֓ཁ ԭೄͱٶ࡚Ͱʮ࣮຿ϨϕϧʯΛ໨ ࢦ͢ํ޲͚ͷϓϩάϥϛϯάε Ϋʔϧ ɾ࢖͏ٕज़ LaravelɺVue.jsͳͲ 1 ձࣾ঺հ
  9. ࣮ݱ͔ͨͬͨ͠࢓༷

  10. ࣮ݱ͔ͨͬͨ͠࢓༷ ྫ

  11. ࣮ݱ͔ͨͬͨ͠࢓༷ ྫ ɾ׽ࣈͰೖྗͨ͠ࡍʹࣗಈͰ;Γ͕ͳ ม׵͢Δ ɾม׵͢Δࡍͷਫ਼౓͸ߴ͍΋ͷ͕ٻΊΒΕ͍ͯͨ ɾม׵εϐʔυ΋0.5ඵҎ্ΛٻΊΒΕ͍ͯͨ

  12. ࣮ݱ͔ͨͬͨ͠࢓༷ ྫ ཁ๬͕ࡉ͔ͯ͘ɺͳ͔ͳ͔ ࣮૷͕೉͍͠…

  13. ࣮ࡍʹ࣮૷ͨ͠ߏ੒

  14. ࠷ॳʹ࢖ͬͨϥΠϒϥϦ vue-autokana-sample vue.jsͰࣗಈͰ;Γ͕ͳΛೖྗ͢Δ ͨΊͷαϯϓϧʹͳΓ·͢ɻ ར༻ϥΠϒϥϦ͸ɺʮterrierscript/ historykanaʯʹͳΓ·͢ɻ https://github.com/idani/vue-autokana-sample

  15. ໰୊఺ ɾม׵଎౓͸଎͍ ɾ͚ΕͲɺม׵ͷਫ਼౓͸͋·Γߴ͘ͳ͍ɻ ɾ͜ΕͰ͸ɺਫ਼౓௿͍ͱ͓٬͞Μʹ٫Լ͞Εͨɻ

  16. ࣍ʹ࣮૷ͨ͠ํ๏ɹkuromoji.jsͰܗଶૉղੳ https://github.com/takuyaa/kuromoji.js/

  17. kuromori.js ࣙॻݕࡧ ׽ࣈΛܗଶૉղੳ ͻΒ͕ͳม׵ ϩδοΫ ΧλΧφΛͻΒ͕ͳʹ ม׵ͯ͠දࣔ͢Δ גࣜձࣾϦϏϧυ ࣍ʹ࣮૷ͨ͠ํ๏ɹkuromoji.jsͰܗଶૉղੳ

  18. ໰୊఺ ɾม׵଎౓͸஗͍ɻม׵ʹ1.5ඵ΄Ͳ͔͔Δɻ ɾม׵ͷਫ਼౓͸͔ͳΓߴ͍ɻ ɾ͜ΕͰ͸ɺ଎౓͕஗͍ͱ͓٬͞Μʹ٫Լ͞Εͨɻ

  19. Yahoo ϧϏৼΓ API גࣜձࣾϦϏϧυ ׽ࣈΛ͔ͳม׵ https://developer.yahoo.co.jp/webapi/jlp/furigana/v1/furigana.html ࣍ʹ࣮૷ͨ͠ํ๏ɹYahoo API

  20. ໰୊఺ ɾม׵଎౓͸଎͍ɻ ɾม׵ͷਫ਼౓͸ߴ͍ɻ ɾ঎༻ར༻ͩͱYahooଆʹ՝ۚͷਃ੥͕ඞཁɻ ɾ͜ΕͰ͸ɺ͓͕͔͔ۚΔͱɺ͓٬͞Μʹ٫Լ͞Εͨɻ

  21. ɾແྉͰ׽ࣈͷม׵ͷ଎౓΋ਫ਼౓Λߴ͘͢Δͷ͸ ೉͔ͬͨ͠…ʂ ୭͔ྑ͍΍Γํ͋ͬͨΒɺڭ͍͑ͯͩ͘͞ʂʂʂ ·ͱΊ