Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
This was discussed in #757. Couldn't see Tim's code in that issue so not sure how he originally implemented this, but hopefully I'm not too far of.
Ideas for performance improvements is more than welcome. It still takes a bit to insert 5k+ rows.
In short it will create a transaction and insert all the rows within that transaction.
knex.batchInsert(tableName, rows, chunkSize = 1)