import 'package:flutter/material.dart';
import 'package:get/get.dart';

import '../../app.dart';

class SettingsController extends GetxController with StateMixin<Type> {
  late final AnimationController ac;

  RxList<CMSModel>  cmsList = <CMSModel>[].obs;
  RxBool isLoading = false.obs;

  @override
  void onInit() {
    debugPrint('SettingsController: onInit()');
    getCMS();
    super.onInit();
  }

  Future<void> getCMS() async {
    isLoading.value = true;

    final result = await CMSApi.get();

    cmsList.addAll(result);

    isLoading.value = false;
  }
}
