NansD / use-airtable-crud

a simple hook to create, read, update and delete records in Airtable

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

use-airtable-crud

npm version npm downloads

Install

npm install --save airtable use-airtable-crud

Usage

const { records, createRecord, updateRecord, deleteRecord, getRecords, loading } = useAirtable(
    'TABLE_NAME',
    AIRTABLE_API_KEY,
    'TABLE_BASE_ID',
    {
      // optionally, you can add some selectOptions
      filterByFormula: '{myField} = TRUE()',
    },
  );

How was it built ?

I used this template to build this project. Thank you @kotarella1110 for the great work!

This hook is heavily inspired from this one, but it has some bugs and looks unmaintained so I decided to make my own.

About

a simple hook to create, read, update and delete records in Airtable

License:MIT License


Languages

Language:TypeScript 65.1%Language:JavaScript 34.9%