How to create E-way bill and E-invoice directly/automatically after creating an invoice on web?

While creating the invoice, we request you to turn on the toggle to create E-invoice.