Self-sanitizing reference fields

Hi everyone,

by way of shameless self-promotion: Here’s an example of how to implement a reference list column that sanitizes itself. This means it won’t turn red when users type (or paste) stupid things into it that aren’t referencable records at all. Instead, it will create new references containing said stupid things, then link to those.

It’s a nice way of making Grist even more usable to Excel-socialised people. Take a look:

https://docs.getgrist.com/t8GrTQaQ2CvF/showcase/p/9/m/fork

The magic behind this comes from a little function I wrote a while ago, and which the trigger formula for the reference column reuses according to the “RUC” concept I’m trying to promote here. So as I said, shameless advertising, but please do take a look. :smiley:

5 Likes

Whoa, this is wild:

And this is wilder :exploding_head:

https://docs.getgrist.com/t8GrTQaQ2CvF/showcase/m/fork/p/code

Very cool and impressive, @TomNit !

2 Likes

Very nice @TomNit — I have looked at the github repo you set up — great to see you that you have taken the initiative.