Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Ruby2.7の機能を使いたくてruby-next使ってみた/try-using-ruby-next
Search
Masatoshi Moritsuka
July 25, 2020
Programming
0
120
Ruby2.7の機能を使いたくてruby-next使ってみた/try-using-ruby-next
Masatoshi Moritsuka
July 25, 2020
Tweet
Share
More Decks by Masatoshi Moritsuka
See All by Masatoshi Moritsuka
gem_rbs_collection へのコントリビュートから始める Ruby の型の世界/contributing-gem-rbs-collection
sanfrecce_osaka
0
140
Rails と人魚の話/rails-and-mermaid
sanfrecce_osaka
0
270
パターンマッチ使ってるかい?(kyobashi.rb)/use-ruby-s-pattern-matching-on-kyobashi-rb
sanfrecce_osaka
0
130
ApplicationController の継承を分割してエラーを減らした話/dividing-application-controller
sanfrecce_osaka
1
200
Input object ではじめる入力値検証/input-value-validation-using-input-object
sanfrecce_osaka
0
390
実例で学ぶRailsアプリケーションデバッグ入門 〜ログインできちゃってました編〜/rails-application-debug-introduction
sanfrecce_osaka
2
680
String#split何もわかっていなかった/didn_t_know_anything_about_string_split
sanfrecce_osaka
0
120
String#split何もわかっていなかった/didn-t-know-anything-about-string-split
sanfrecce_osaka
0
52
パターンマッチ使ってるかい?/use-ruby-s-pattern-matching?
sanfrecce_osaka
0
800
Other Decks in Programming
See All in Programming
EMになってからチームの成果を最大化するために取り組んだこと/ Maximize team performance as EM
nashiusagi
0
100
Enabling DevOps and Team Topologies Through Architecture: Architecting for Fast Flow
cer
PRO
0
340
macOS でできる リアルタイム動画像処理
biacco42
9
2.4k
OnlineTestConf: Test Automation Friend or Foe
maaretp
0
120
AI時代におけるSRE、 あるいはエンジニアの生存戦略
pyama86
6
1.2k
カンファレンスの「アレ」Webでなんとかしませんか? / Conference “thing” Why don't you do something about it on the Web?
dero1to
1
110
Ethereum_.pdf
nekomatu
0
470
A Journey of Contribution and Collaboration in Open Source
ivargrimstad
0
1k
Duckdb-Wasmでローカルダッシュボードを作ってみた
nkforwork
0
130
Tauriでネイティブアプリを作りたい
tsucchinoko
0
370
C++でシェーダを書く
fadis
6
4.1k
Jakarta EE meets AI
ivargrimstad
0
710
Featured
See All Featured
Music & Morning Musume
bryan
46
6.2k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
Building Applications with DynamoDB
mza
90
6.1k
Gamification - CAS2011
davidbonilla
80
5k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.1k
For a Future-Friendly Web
brad_frost
175
9.4k
Mobile First: as difficult as doing things right
swwweet
222
8.9k
Intergalactic Javascript Robots from Outer Space
tanoku
269
27k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.8k
BBQ
matthewcrist
85
9.3k
How to train your dragon (web standard)
notwaldorf
88
5.7k
The Art of Programming - Codeland 2020
erikaheidi
52
13k
Transcript
Ruby2.7 ͷػೳΛ͍ͨͯ͘ ruby-next ͬͯΈͨ ௩ ਅ(@sanfrecce_osaka) 2020/07/25 Kaigi on Rails
new #kaigionrails
ࣗݾհ ➤ ௩ ਅ ➤ GitHub: @sanfrecce-osaka ➤ Twitter: @sanfrecce_osaka
➤ Qiita: @sanfrecce_osaka ➤ 20199݄: େࡕ → ொా ➤ גࣜձࣾϥάβΠΞ ➤ ruby-jpͷॅਓ ➤ ίϛϡχςΟɾษڧձΦλΫ
ʲએʳຖ݄ୈҰ༵ۚʹ Machida.rb ͬͯ·͢
࠷ۙͷࣄͷ
Rails API + TypeScript + React
େྔͷ any
@typescript-eslint/no-explicit-any=>8544
rspec-openapi
request spec ↓ Open APIܗࣜ ͷ υΩϡϝϯτ
͜Εָ
But
ੜ͞ΕΔ yaml͔Β TSͷܕΛॻ͘ͷਓྗ
Let's making a gem!!
Gem Λ࡞Δʹ ͋ͨͬͯ
yaml Λ ύʔε͢Δ ඞཁ͕͋Δ
ύλʔϯϚονϯά ͍͍ͨ
φϯύϥ ͍͍ͨ
But
ϓϩδΣΫτͷRuby 2.5.0
ͦ͜Ͱ ruby-next
ruby-next ➤ Ruby ΛτϥϯεύΠϧͯ͘͠ΕΔ Gem ➤ ΞϓϦέʔγϣϯଆ => ϥϯλΠϜϞʔυ ➤
ϥΠϒϥϦଆ => CLI ͔ΒτϥϯεύΠϧ(ࠓճͬͪ͜) ➤ Refinements Λར༻͍ͯ͠Δ ➤ αϙʔτൣғ͕͍ ➤ https://github.com/ruby-next/ruby-next/blob/master/ SUPPORTED_FEATURES.md
ҙ ➤ require_relative Ͱͳ͘ require Ͱͳ͍ͱͩΊ ➤ τϥϯεύΠϥ rewirteϞʔυ ͱ
ASTϞʔυ ͷ 2छ ➤ σϑΥϧτ ASTϞʔυ ➤ 2.7ܥ Ͱ rewriteϞʔυ ͷΈ ➤ ಛఆͷػೳ໌ࣔతʹΦϓγϣϯΛࢦఆ͢Δඞཁ͕͋Δ
σϞ
࠷ޙʹ
ruby-next Ͱ 2.7 2.8 ʹ৮ΕΔਓ͕ ૿͑ͯ΄͍͠ʙ
͝ਗ਼ௌ ͋Γ͕ͱ͏ ͍͟͝·ͨ͠ʂ