Posting this here after I created an issue ticket: Add `jsonb` on sqlite connection adapter table definition · Issue #50841 · rails/rails · GitHub
With the addition of a binary json on disk format in sqlite, we sort of have a jsonb now. The column type is still json, however the format in which it is stored is jsonb. Making all json fields technically jsonb. M
I believe it would be a welcome addition to have an aliased column helper called jsonb
which creates a json column in sqlite.
Reasoning
Most of the time, we start off with sqlite and move to postgres. Which requires changing all our json columns to jsonb. Adding this alias allows us to use the same migrations across sqlite and postgres successfully.
I’m happy to take a stab at a PR if this is a welcome change.