Slide 1

Slide 1 text

FlutterͷBarrel Fileʹ ͍ͭͯ 2023/07/24 Daiki Asahi (ashdik) 1

Slide 2

Slide 2 text

ே೔େथˏ 5XJUUFSɿ!EBJLJ 'MVUUFSྺɿϲ݄ ϒϩάɿIUUQTCMPHEBMUNF

Slide 3

Slide 3 text

໨࣍ ɾBarrel Fileͱ͸ʁ ɾimport͸ॏཁͳͷ͔ʁ ɾexportΩʔϫʔυ ɾBarrel Fileͷ࡞Γํ 3

Slide 4

Slide 4 text

໨࣍ ɾBarrel Fileͱ͸ʁ ɾimport͸ॏཁͳͷ͔ʁ ɾexportΩʔϫʔυ ɾBarrel Fileͷ࡞Γํ 4

Slide 5

Slide 5 text

Barrel Fileͱ͸ʁ 5 importΛ·ͱΊͨϑΝΠϧ 5

Slide 6

Slide 6 text

໨࣍ ɾBarrel Fileͱ͸ʁ ɾimport͸ॏཁͳͷ͔ʁ ɾexportΩʔϫʔυ ɾBarrel Fileͷ࡞Γํ 6

Slide 7

Slide 7 text

7 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 7

Slide 8

Slide 8 text

υϝΠϯ ͲͷυϝΠϯ͕ͲͷυϝΠϯΛ஌͍ͬͯΔ͔ ϨΠϠʔ ٯࢀর͸ආ͚ͯɺґଘؔ܎ΛҰํ޲ʹ 8 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 8

Slide 9

Slide 9 text

υϝΠϯ ͲͷυϝΠϯ͕ͲͷυϝΠϯΛ஌͍ͬͯΔ͔ ϨΠϠʔ ٯࢀর͸ආ͚ͯɺґଘؔ܎ΛҰํ޲ʹอͪ·͢ɻ 9 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 9

Slide 10

Slide 10 text

υϝΠϯ ͲͷυϝΠϯ͕ͲͷυϝΠϯΛ஌͍ͬͯΔ͔ ϨΠϠʔ ٯࢀর͸ආ͚ͯɺґଘؔ܎ΛҰํ޲ʹอͪ·͢ɻ 10 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 10 YOUTRUSTΞϓϦͷߏ଄ɺ๫࿐ͯ͠Έͨ more infoʁ https://speakerdeck.com/daiki1003/youtrustapurifalsegou-zao-bao-lu-sitemita

Slide 11

Slide 11 text

υϝΠϯ ͲͷυϝΠϯ͕ͲͷυϝΠϯΛ஌͍ͬͯΔ͔ ϨΠϠʔ ٯࢀর͸ආ͚ͯɺґଘؔ܎ΛҰํ޲ʹ 11 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 11

Slide 12

Slide 12 text

υϝΠϯ ͲͷυϝΠϯ͕ͲͷυϝΠϯΛ஌͍ͬͯΔ͔ ϨΠϠʔ ٯࢀর͸ආ͚ͯɺґଘؔ܎ΛҰํ޲ʹ 12 importจͷॏཁੑ ͲͷϑΥϧμʹґଘ͍ͯ͠Δ͔ʁ 12 Flutter੡YOUTRUSTΞϓϦΛࢧ͑ΔϨΠϠʔߏ੒ more infoʁ https://tech.youtrust.co.jp/entry/app-layer-flutter

Slide 13

Slide 13 text

໨࣍ ɾBarrel Fileͱ͸ʁ ɾimport͸ॏཁͳͷ͔ʁ ɾexportΩʔϫʔυ ɾBarrel Fileͷ࡞Γํ 13 13

Slide 14

Slide 14 text

DartϥΠϒϥϦͷҰ෦Λɺ ଞͷϥΠϒϥϦʹެ։͢ΔͨΊʹ࢖༻͢Δ 14 exportΩʔϫʔυ exportΩʔϫʔυͱ͸ʁ 14

Slide 15

Slide 15 text

໨࣍ ɾBarrel Fileͱ͸ʁ ɾimport͸ॏཁͳͷ͔ʁ ɾexportΩʔϫʔυ ɾBarrel Fileͷ࡞Γํ 15 15

Slide 16

Slide 16 text

16 Barrel Fileͷ࡞Γํ 16 lib/comic ᵓᴷᴷ model ɹ ᵓᴷᴷ attack_on_titan.dart ɹ ᵓᴷᴷ hunter_hunter.dart ɹ ᵓᴷᴷ kingdom.dart ɹ ᵋᴷᴷ one_piece.dart

Slide 17

Slide 17 text

17 Barrel Fileͷ࡞Γํ 17 lib/comic ᵓᴷᴷ model ᴹ ᵓᴷᴷ attack_on_titan.dart ᴹ ᵓᴷᴷ hunter_hunter.dart ᴹ ᵓᴷᴷ kingdom.dart ᴹ ᵋᴷᴷ one_piece.dart ᵋᴷᴷ model.dart

Slide 18

Slide 18 text

18 Barrel Fileͷ࡞Γํ 18 Before After

Slide 19

Slide 19 text

19 Barrel Fileͷ࡞Γํ 19 શ෦ख࡞Γʁ

Slide 20

Slide 20 text

20 Barrel Fileͷ࡞Γํ 20 શ෦ख࡞Γʁ εΫϦϓτͷར༻ Dart Barrel File Generator

Slide 21

Slide 21 text

21 importจͷॏཁੑ ୹͍/গͳ͍͕ਖ਼ٛͰ͸ͳ͍ 21

Slide 22

Slide 22 text

lib.dartʁ 22 importจͷॏཁੑ ୹͍/গͳ͍͕ਖ਼ٛͰ͸ͳ͍ 22

Slide 23

Slide 23 text

23 ·ͱΊ Barrel FileΛ࢖͏͜ͱͰimportΛߏ଄Խग़དྷΔ 23 importจ͸ͲͷϑΝΠϧ͕ͲͷϑΝΠϧʹґଘ͍ͯ͠Δ͔Λ஌ΔࢦඪͰ͋Δ ༻๏ɾཁྖΛकͬͯਖ਼͓͘͠࢖͍͍ͩ͘͞

Slide 24

Slide 24 text

24 24 ͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠ʂ