Giter VIP home page Giter VIP logo

mmm-airtable's Introduction

MMM-Airtable

This a module for the MagicMirror.

It can display your Table(s) from your Airtable and update them at a regular interval. Check the screenshots for more details.

Installation

  1. Navigate into your MagicMirror modules folder and execute git clone https://github.com/yashatgit/MMM-Airtable.git.
  2. Enter the MMM-Airtable directory and execute npm install. cd MMM-Airtable && npm install.

Airtable API configuration

Go to https://airtable.com/api and select the base to view its API documentation. Click the Javascript version of the Sample API. (Just search for the keyword apiKey and you will find the relevant details.)

We would need following details for the module to fetch the data:

  1. API key
  2. Base id
  3. Table name(s)

Module Config

Option Description
airtableAPIKey REQUIRED API Key for Airtable.

Type: string
airtableBaseId REQUIRED Airtable Base ID.

Type: string
animationSpeed Table refresh change animation time in ms.

Type: number
Defaults to 1500
updateInterval Interval for refetching the latest data.

Type: number
Defaults to 60*1000 (i.e. one minute).
tables A list of table configurations. See Table below for more details.

Type: array

Each object in the tables array can have the following parameters:

Option Description
workspaceName REQUIRED Name of the Workspace Tab/Table.

Type: string
tableTitle Optional title for your table. How you would like this displayed on your MagicMirror?

Type: string
maxRows Optional number to limit the maximum rows to be displayed.

Type: number
Defaults to 20
updateInterval Optional interval for refetching the latest data. Overrides the value from updateInterval in main config.

Type: number
rowBorder Optional bool check to show Borders below each row.

Type: boolean

Example of an entry in `config.js` which displays 2 tables as shown in Screenshot
{
  module: 'MMM-Airtable',
  position: 'top_right',
  config: {
	airtableAPIKey: '<YOUR_API_KEY>',
	airtableBaseId: '<YOUR_BASE_ID>',
	animationSpeed: 1.5 * 1000,
	updateInterval: 1000 * 50, //refresh after 50 sec
	tables: [
	  {
		workspaceName: 'Meal Planner',
		tableTitle: 'Meal Planner',
		maxRows: 7,
        	rowBorder: true, //shows row borders
	  },
	  {
		workspaceName: 'Todos',
		tableTitle: 'To Do',
		maxRows: 8,
	  },
	],
  },
},

Screenshots

mmm-airtable's People

Contributors

yashatgit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mmm-airtable's Issues

Airtable deprecating API keys

No longer able to get an API key on Airtable - it's forcing you to ab OAuth and I can't get that to work, I just get "loading..."

Field order

If a field is empty for a record, it will populate the field in MMM-Airtable with the next field that is not empty. If I then put data in the field (in Airtable), it keeps the data it already has and will put it's new data in the field next to it. I can solve this by deleting the record and re-entering it in Airtable but this gets cumbersome and unpredictable. Sometimes the values for the fields get all mixed up.

Also, the columns are not always displayed in MMM-Airtable in the same order that they are in Airtable.

Thanks,
Russell

[Feature Request] Specify columns or conditional fields

Hello, really appreciate this plugin for MagicMirror thank you so much for your work here!
I just installed it and noted a few errors on install. npm audit fix --force seemed to fix it up fine.

I would love the ability to specify which columns are displayed, would be useful for only showing pertinent information. The other thing I was thinking would be neat is to only show rows based on conditional fields, however perhaps this is best managed on the airtable side. I was trying to hide columns so they didn't show up, but of course the API pulls everything. Cheers.

Installation

I don't know that this is an issue but I followed the installation directions, a few times, and cannot get this to work. I am getting a "Loading..." indication on the screen but nothing to display. I tried a couple bases and tables but it still won't load something. Is there anywhere you can tell me to start looking for an issue?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.