Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
BuefyのMaintainerを引き継いだ件
Search
Kikuo Emoto
March 07, 2024
Programming
1
1k
BuefyのMaintainerを引き継いだ件
Vue.js v-tokyo Meetup #19
https://vuejs-meetup.connpass.com/event/309755/
Kikuo Emoto
March 07, 2024
Tweet
Share
More Decks by Kikuo Emoto
See All by Kikuo Emoto
aws-smithy-mocksを使ってみよう
kikuomax
0
46
Other Decks in Programming
See All in Programming
モダンJSフレームワークのビルドプロセス 〜なぜReactは503行、Svelteは12行なのか〜
fuuki12
0
150
ZOZOにおけるAI活用の現在 ~モバイルアプリ開発でのAI活用状況と事例~
zozotech
PRO
7
3k
スタートアップを支える技術戦略と組織づくり
pospome
8
13k
Stay Hacker 〜九州で生まれ、Perlに出会い、コミュニティで育つ〜
pyama86
2
3k
Combinatorial Interview Problems with Backtracking Solutions - From Imperative Procedural Programming to Declarative Functional Programming - Part 1
philipschwarz
PRO
0
110
FluorTracer / RayTracingCamp11
kugimasa
0
110
jakarta-security-jjug-ccc-2025-fall
tnagao7
0
100
非同期処理の迷宮を抜ける: 初学者がつまづく構造的な原因
pd1xx
1
300
AIと協働し、イベントソーシングとアクターモデルで作る後悔しないアーキテクチャ Regret-Free Architecture with AI, Event Sourcing, and Actors
tomohisa
5
12k
[SF Ruby Conf 2025] Rails X
palkan
0
390
Herb to ReActionView: A New Foundation for the View Layer @ San Francisco Ruby Conference 2025
marcoroth
0
210
Reactive Thinking with Signals and the new Resource API
manfredsteyer
PRO
0
140
Featured
See All Featured
Scaling GitHub
holman
464
140k
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.6k
The World Runs on Bad Software
bkeepers
PRO
72
12k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
22k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
48
9.8k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
The Power of CSS Pseudo Elements
geoffreycrofte
80
6.1k
Writing Fast Ruby
sferik
630
62k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
34
2.3k
Fireside Chat
paigeccino
41
3.7k
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Transcript
,JLVP݄ #VFGZͷ.BJOUBJOFSΛҾ͖ܧ͍ͩ݅ ࠓߋͳ͕Β7VFˠͷΓ͑ۤ࿑
ࣗݾհ ,JLVPߐຊتٱஉ w ϑϦʔϥϯεͷԿͰ w ࠷ۙͷྲྀߦΓ3VTU 5ZQF4DSJQU "844FSWFSMFTT "84$%, w
ϓϩάϥϛϯάҎ֎ͷझຯֆɺΔ͜ͱ w ͖ͳΞΠεϗοέʔνʔϜ1JUUTCVSHI1FOHVJOT LJLVPNBY DPEFNPOHFSJP
#VFGZͱ IUUQTCVFGZPSH w #VMNBϕʔεͷ7VFKT༻ܰྔ6*ίϯϙʔωϯτ w ެࣜ൛ CFVGZ! 7VFઐ༻ #VFGZGPS7VF
w ։ൃ൛ !OUPIRCVFGZOFYU 7VFઐ༻ #VFGZGPS7VF
#VFGZ.BJOUBJOFSͷมભ w ݪ࡞ऀ!SBGBCFSBMEP w લͷ.BJOUBJOFS!KUPNNZ w ݄ʙ!XFTEFWQSP !LJLVPNBY ࢲ
w ͦͷଞଟ͘ͷίϯτϦϏϡʔλʹࢧ͑ΒΕ͍ͯ·͢
FYUFOEͷഇࢭ QSPQͷॳظԽͱUIJT 7VF
FYUFOEͷഇࢭ QSPQͷॳظԽͱUIJT 7VF
FYUFOEͷഇࢭ w #VFGZͷศརػೳ w ίϯϙʔωϯτΛ໌ࣔతʹຒΊࠐ·ͳͯ͘ϞʔμϧΛදࣔͰ͖Δ 1SPHSBNNBUJDػೳ this.$buefy.dialog.alert('Everything looks fine!')
FYUFOEͷഇࢭ #VFGZGPS7VFͷ࣮ w άϩʔόϧͳ7VFΠϯελϯεΛFYUFOE͠ɺಈతʹੜͨ͠%0.ʹϞʔμϧ ΛϚϯτ const ModalComponent = window.Vue.extend(Modal) const
component = new ModalComponent({ el: document.createElement('div') }) ࣮ࡍͷίʔυΛ؆ུԽ 7VFͰFYUFOEഇࢭ
FYUFOEͷഇࢭ #VFGZGPS7VFͷ࣮ެ։"1*ͷΈͰ࣮ w DSFBUF"QQͰ৽͍͠"QQΠϯελϯεΛ࡞ͯ͠ϞʔμϧΛϚϯτ const vueInstance = createApp({ render() {
return h(Modal, { onClose: () => vueInstance.unmount() }) } }) vueInstance.mount(document.createElement('div')) ࣮ࡍͷίʔυΛ؆ུԽ ϝΠϯͷ"QQʹΠϯετʔϧͨ͠ϓϥάΠϯ͕ϞʔμϧͰ͑ͳ͍
FYUFOEͷഇࢭ #VFGZGPS7VFͷ࣮ݱঢ় w ϝΠϯ"QQͷ"QQ$POUFYU @DPOUFYU ͷதΛ৽͍͠"QQʹίϐʔ const { _context: srcContext
} = mainApp const { _context: destContext } = destApp destContext.config = srcContext.config destContext.mixins = srcContext.mixins destContext.components = srcContext.components destContext.directives = srcContext.directives destContext.provides = srcContext.provides destContext.optionsCache = srcContext.optionsCache destContext.propsCache = srcContext.propsCache destContext.emitsCache = srcContext.emitsCache if ('__VUE_I18N_SYMBOL__' in mainApp) { destApp.__VUE_I18N_SYMBOL__ = mainApp.__VUE_I18N_SYMBOL__ } Πϯετʔϧ࣌ʹ͓֮͑ͯ͘ 👎ଞͷϓϥάΠϯͱͷ૬ੑ ࣮ࡍͷίʔυΛ؆ུԽ 👎7VFͷ෦ߏʹґଘ͗͢͠
FYUFOEͷഇࢭ QSPQͷॳظԽͱUIJT 7VF
QSPQͷॳظԽͱUIJT #VFGZGPS7VFͷ࣮ w λϒදࣔͳͲͰҰ෦QSPQͷॳظԽʹ7VFͷ෦ϑΟʔϧυUIJT@VJEΛ༻ w ͷলུ࣌ʹϢχʔΫ͞Λอূ͢ΔͨΊ props: { value: {
type: String, default() { return this._uid.toString() } } } ࣮ࡍͷίʔυΛ؆ུԽ 7VFͰQSPQͷσϑΥϧτؔͰUIJTΛ༻Ͱ͖ͳ͍ ˠ୯७ʹUIJTVJEʹஔ͖͑ΒΕͳ͍
QSPQͷॳظԽͱUIJT #VFGZGPS7VFͷ࣮۪൛ w ϥϯμϜͳͰQSPQΛॳظԽͯ͠ϢχʔΫ͞Λอূ // props: { value: { //
type: String, // default() { return makeUniqueId() } // }} function makeUniqueId() { const values = new Uint8Array(12) window.crypto.getRandomValues(values) return Array.prototype.map.call( values, (v) => v.toString(16) ).join(‘') } ࣮ࡍͷίʔυΛܗ 4FSWFS4JEF3FOEFSJOH 443 ͰXJOEPXͱཚޚ๏
QSPQͷॳظԽͱUIJT #VFGZGPS7VFͷ࣮ݱঢ় w QSPQΛOVMMͰॳظԽ͠ɺDPNQVUFEͰUIJTVJEʹϑΥʔϧόοΫ props: { value: { type: String,
default: null } }, computed: { uniqueValue() { return this.value != null ? this.value : this.$.uid } } ࣮ࡍͷίʔυΛ؆ུԽ
FYUFOEͷഇࢭ QSPQͷॳظԽͱUIJT 7VF
7VF w 7VFͷҠߦ࡞ۀͷେ݄ʙ݄ࠒˠ7VF w 7VFͷมߋ͕Өڹ
7VF มߋWGPSதͷSFG w WGPSதͷSFGྻͱͯ͠ΞΫηεՄೳʹ w 7VFͱಉ͡ڍಈʹͬͨˠ7VF༻ͷରࡦ͕ٲʹ 7VFެࣜυΩϡϝϯτ IUUQTKBWVFKTPSHHVJEFFTTFOUJBMTUFNQMBUFSFGTSFGTJOTJEFWGPS ΑΓൈਮ ˡ
7VF ͪͬͱϚΠφʔ͡Όͳ͍ϚΠφʔνΣϯδ w 7VF ʙͷڍಈWGPSͷ࠷ޙͷཁૉͷΈSFGTʹ֨ೲ ඇྻ w SFG໊ʹΠϯσοΫεΛՃ໊ͯ͠લͷॏෳΛճආ <li
v-for="childItem in items" :key="childItem.value"> <a :ref="`tabLink${childItem.index}`">{{ childItem.label }}</a> </li> const tab = this.$refs[`tabLink${index}`] tab.focus() ࣮ࡍͷίʔυΛ؆ུԽ ࣮ࡍͷίʔυΛ؆ུԽ
7VF ϋΠϒϦου w SFG໊ʹΠϯσοΫεΛՃ໊ͯ͠લͷॏෳΛճආ w SFGT͕ྻ͔൱͔Ͱόʔδϣϯఆ const tab = this.$refs[`tabLink${index}`]
if (Array.isArray(tab)) { tab = tab[0] } tab.focus() ࣮ࡍͷίʔυΛ؆ུԽ WҎ߱ˠཁૉͷྻ
ެࣜϦϦʔεʹ͚ͯ w 5ZQF4DSJQUͷҠߦ w ෆ۩߹मਖ਼ w ࡉ͔͍#VFGZGPS7VFͱͷඇޓੑͷൃݟͱରԠ w "1*υΩϡϝϯτͷߋ৽ w
/VYU༻ͷϞδϡʔϧ։ൃ ͝ࢼ༻ɾίϯτϦϏϡʔγϣϯ͓͍ͪͯ͠·͢ IUUQTHJUIVCDPNOUPIRCVFGZOFYU