Writing backwards makes it easier to batch requests for better performance when writing a doc programmatically with the Google Docs API. Start at the end and finish with the title, no more tracking indexes, happy batching!
Google Docs API → https://goo.gle/2X6egtp
Document Structure Guide → https://goo.gle/2JC0Q5h
Product:; fullname: Anu Srivastava;
Publisher: Google Cloud
You can watch this video also at the source.