Created
March 27, 2022 19:20
-
-
Save charltoons/c4a85e5995d8bac8b67e87460c9bedcd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is a partial script to get the Table of the current record. | |
// It allows you to avoid hardcoding the table name in `base.getTable()`. | |
// You need to set up an input of the current Record URL using the name `recordUrl`. | |
const inputConfig = input.config() | |
const recordUrl = new URL(inputConfig.recordUrl) | |
const tableId = recordUrl.pathname.split('/')[2] | |
const table = base.getTable(tableId) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment