This is how I beat the Ender Dragon. No joke In case you didn’t know, when you try to sleep in The End, the beds explode. Yes they EXPLODE
What I Did: Step 1. Get a good sword, a shield, armour and a bunch of beds Step 2. Go to The End Step 3. Use the /summon command to spawn an Iron Golem (or as many as you need) this will distract the endermen. Step 4. Sleep near the End Crystals (don’t forget to heal yourself using potions or just wait) Step 5. Attack!!!!!