{"width":"100%","provider_url":"https://hatena.blog","type":"rich","categories":[],"url":"https://hisaichi5518.hatenablog.jp/entry/2019/12/05/230810","author_name":"hisaichi5518","title":"get_it \u3092\u4f7f\u3063\u3066\u3044\u305f\u3051\u3069\u3084\u3081\u305f","image_url":null,"author_url":"https://blog.hatena.ne.jp/hisaichi5518/","provider_name":"Hatena Blog","version":"1.0","description":"get_it | Dart Package \u3092\u4f7f\u3063\u3066\u3044\u305f\u304c\u3084\u3081\u305f\u3002 // \u767b\u9332\u3055\u3048\u3059\u3070 GetIt.instance.registerSingleton<Logger>(Logger()); // \u3069\u306e\u30af\u30e9\u30b9\u3067\u3082Logger\u3092\u53c2\u7167\u3067\u304d\u308b class HogeBloc { final Logger logger = GetIt.instance.get<Logger>(); } \u4fbf\u5229\u306a\u3093\u3060\u3051\u3069\u6b21\u306e\u554f\u984c\u304c\u3042\u308b\u3068\u601d\u3063\u305f\u3002 \u30af\u30e9\u30b9\u304c\u306a\u3093\u306e\u578b\u306b\u4f9d\u5b58\u3057\u3066\u3044\u308b\u306e\u304b\u5916\u304b\u3089\u308f\u304b\u3089\u306a\u3044 GetIt \u306e instance \u306b\u4f9d\u5b58\u3059\u308b\u3053\u3068\u306b\u306a\u308a\u3001\u30c6\u30b9\u30c8\u3067\u3082\u4f9d\u5b58\u3059\u308b BuildContext \u306b\u4f9d\u5b58\u3057\u305f\u304f\u306a\u3044\u304b\u3089\u30e2\u30c7\u30eb\u2026","blog_title":"\u30d1\u30eb\u30ab\u30ef2","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fhisaichi5518.hatenablog.jp%2Fentry%2F2019%2F12%2F05%2F230810\" title=\"get_it \u3092\u4f7f\u3063\u3066\u3044\u305f\u3051\u3069\u3084\u3081\u305f - \u30d1\u30eb\u30ab\u30ef2\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","height":"190","blog_url":"https://hisaichi5518.hatenablog.jp/","published":"2019-12-05 23:08:10"}