How to show and hide loading image

I need to show and hide a loading image as my records is being fetched from airtable using the documentation code below

import { Loader } from "@airtable/blocks/ui";
const loaderExample = <Loader scale={0.3} />;

here is my code. can someone help me


import {initializeBlock, Loader, useBase, useRecords, table} from '@airtable/blocks/ui';
import React, { Component } from "react";
import {base} from '@airtable/blocks';

function Access (){ 
const base = useBase();
 const tab = base.getTableByNameIfExists('empoyee_table');
 const records = useRecords(tab);
return (

   <h1>Show Employee Records</h1> <br />

             { => {

                 return <li key={}>{}</li>
initializeBlock(() => <Access />);

export default Access;

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.