This repository was archived by the owner on Oct 9, 2023. It is now read-only.
Repository navigation
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Character limit improvements
Before this release, the initial
transform.tsconfig that snaplet generates for you would make use ofcopycat.scramble()to transform the string if the relevant column had a character limit (e.g.varchar(50)).In this release, we now make use of copycat's new
limitoption when the relevant copycat API method supports thelimitoption. We are still adding thelimitoption to the rest of copycat's API, for cases wherelimitisn't available yet we still make use ofscramble()Subsetting improvements
Our subsetting feature now lets you to specify additional foreign keys that should be used when subsetting. This also gives you a way to tell Snaplet to also include related tables with nullable foreign keys (these are by default not included in the resulting subset).
For example, if you had a table
usersand a related tablestaff, then you could ensure that the staff table gets included with a config like this:{ "enabled": true, "initial_targets": [ { "table": "public.users", "row_limit": 10 } ], "keep_disconnected_tables": true, "foreign_keys": [ { "table": "public.staff", "column": "user_id", "targetTable": "public.users", "targetColumn": "staff_id" } ] }Bug fixes
structure.tsfile we generate (which includes the typescript types fortransform.ts) did not generate valid typescript if for cases where there were tables or columns that did not start with a letter (for example, table names that start with numbers)All reactions