Skip to content

skeleton.showOriginal() not showing  #41

@MhmmdRFadhil

Description

@MhmmdRFadhil

is there something wrong with the following script? because the original data does not appear

private fun getData() {
        newsViewModel.getNewsList().observe(viewLifecycleOwner) {
            when (it) {
                is Response.Loading -> skeleton?.showSkeleton()
                is Response.Success -> {
                    skeleton?.showOriginal()
                    newsAdapter.add(it.data)
                }

                is Response.Fail -> {
                    it.e.message.toString().snackBarErrorMessage(activity as MainActivity)
                    skeleton?.showSkeleton()
                }
            }
        }
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions