import 'dart:convert'; import 'package:flutter/services.dart'; class ContentProvider { ContentProvider._(); static const String _jsonPath = 'assets/content.json'; static Future init() async { try { String file = await rootBundle.loadString(_jsonPath); _content = json.decode(file); } catch (e) { return false; } return true; } static Map _content = {}; static List get experience => _content['experience']; static List> get education => _content['education']; static List> get skills => _content['skills']; }